Saphan StudioDocs
Reference/Command reference

saphan order

Order sidecars: sign a document under a delegate (or root) key

saphan order

Order sidecars: sign a document under a delegate (or root) key

saphan order

Subcommands

SubcommandWhat it does
saphan order showReturn a registered order's exact bytes from its recorded commit
saphan order signSign <path>'s exact bytes and REGISTER them, printing the ref

saphan order show

Return a registered order's exact bytes from its recorded commit

saphan order show <ref> [flags]

Resolves slug@<hex> (at least 12 lowercase hex characters), a full 64-character digest with or without its slug, then reads the document from the COMMIT stored in its registration. Text format writes only the exact document bytes to stdout and metadata to stderr; JSON carries metadata plus the bytes in base64. A bare short digest is a usage error.

Options

OptionTypeDefaultDescription
--formatstringunsetoutput format: text|json (default: text; global --json/--output-format json also supported)

saphan order sign

Sign <path>'s exact bytes and REGISTER them, printing the ref

saphan order sign <path> [flags]

Signs <path>'s EXACT bytes (no canonicalization, §0a) with the ed25519 private key at --key, writes the composed v1 envelope to <path>.sig (overwriting any prior sidecar — re-signing after an edit is expected; O_EXCL custody lives on the KEY files, not on this output), and then REGISTERS those bytes: one immutable row plus its registered act, in a single transaction, printing the ref they are addressable by.

The signer's key-id is derived from the key itself (sign.ActorKeyID), never taken on faith from a flag — a caller cannot claim a key-id that key does not actually derive to.

--key names EITHER the root private key OR a delegate's private key — this verb signs unconditionally; whether the resulting signature actually authorizes anything is instr.Verify's job at read time (saphan verify), not this verb's.

REGISTRATION RECORDS A COMMIT, so the document must already be committed (the sidecar need not be). A document no landed commit carries refuses with the named class order-uncommitted — and the sidecar stays on disk, because it is a file you asked for and its bytes are correct.

Options

OptionTypeDefaultDescription
--actorstringunsetsigning actor label (flag > SAPHAN_ACTOR > ~/.saphan/config)
--expiresstringunsetRFC3339 expiry; absent means the registration never expires
--keystringunsetsigning private key path (required — root or delegate)
--slugstringunsetregistration slug, the typable half of the ref (default: the document's basename stem)
--tsstringunsetRFC3339 timestamp (default: now)

On this page