Publishing from Marked
Connect your Mac once, then publish the document you are previewing and update it on later shares.
Connect your account
Marked publishes through the Marked Share API, which needs two credentials: an API token that identifies your account and a device key that identifies the machine. Connecting mints both at once.
Start from Connect Marked in
Settings, or let Marked open the connect page for you. Either way
the page lands on share.markedapp.com/auth/marked, shows the API base, and generates
the pair when you confirm. If you are not signed in yet you will be asked to sign in or sign up
first, then returned to the same page.
When Marked opened the page, generating the pair hands them straight back to the app through the
x-marked-3://login deep link, so there is nothing to copy. The credentials still
appear on the page with an Open Marked button, so a launch your browser blocks
or you dismiss by accident is not a dead end. When you opened the page yourself, the token and
device key are simply displayed once for pasting into Marked or a script of your own.
The link is versioned for Marked 3. Marked 2 registers x-marked:// and cannot store
these credentials, so Share only accepts x-marked-3://login as a return target.
Credentials are shown a single time and are not recoverable. If you lose them, connect again to mint a new pair, then revoke the old token under Your tokens in Settings. Naming the credential after the machine — Marked on Sisyphus — makes that list easy to read later.
What publishing sends
Marked packages the document you are previewing as a TextPack, a zipped TextBundle containing the Markdown and any local images it references, and uploads that in one request. Images are stored with the document and the Markdown image paths are rewritten to hosted URLs, so a shared document is never pointing at files on your Mac.
The response includes the share URL, so the app can show you a link to copy or open. Documents created through the API are private unless the request asks for unlisted or public, so you decide when something becomes readable.
If the document carries Marked highlights in a highlights.json file, those come
across too and become your own highlight set on the published copy. See
Highlights and reviews.
An info.json in the archive can also set the published
reading style,
under the com.markedapp.share namespace or as a bare readingStyle
key. Downloads carry the same file, so the typography survives a trip out to Marked and back.
Publishing again after edits
The first publish creates a document; later publishes update that same document, so the share link you already sent out keeps working and readers get a live-update notice.
Updates are guarded against clobbering. Each version has a content hash, and an update must say which version it is replacing. If the copy on the server is newer — you edited it in the browser, or published from another Mac — the update is refused and the app can tell you which device got there first before you decide to overwrite.
| Situation | What happens |
|---|---|
| First publish | A new document is created and its id, hash, and share URL are returned. |
| Publish after local edits | The existing document is replaced, with a new version snapshot in its history. |
| Server copy is newer | The update is rejected as a conflict, naming the device that made the newer change. |
| Token revoked | Requests stop being authorized; connect again to get a fresh pair. |
Pulling reader feedback back into Marked
Reviews collected on the web can travel back to your Mac. Every highlight set has a TextBundle
download that includes a highlights.json in Marked's format, so you can open a
reviewed draft locally with the highlights and notes intact. The
highlights documentation covers the whole loop, and the
API reference lists the endpoints an app or script can use to
fetch reviews directly.
Managing access
Settings lists every token on your account with its name, creation date, and last use. Revoke takes effect immediately and is the right move for a machine you no longer use or a credential you think leaked. Revoking one token does not affect the others, and it never touches your documents.
Menu names and options inside Marked depend on your version of the app. This page describes what Marked Share provides; if Marked does not offer a Share command yet, you can still publish from the web or with the API.