Skip to main content
bijection speaks the same words as your code. Its verbs are the ctx verbs and the client verbs, its flags are their option keys, and its addresses are tree paths. Run bijection --help to list the commands of your installed version, and bijection <command> --help for one command’s inputs.

Select a deployment

dev installs the tree on the selected development deployment and watches your source. Use --installation <project>:<name> to direct one invocation to an explicit deployment. A Git checkout changes the source on disk; deployment selection is a separate CLI setting.

Deploy

Production takes an explicit target or its deploy key. Deploy refuses a tree whose derived lock differs from the committed bijection.lock (AuthorityLockStale). It also refuses to remove a release that stored facts still depend on for a pending lowering. See Deploys for building an immutable release and deploying it later.

Call an installed function

Use the dotted function path from your app tree. The mount supplies the prefix, so a library mounted at etl exposes its refresh as etl.refresh. The selected installation supplies help and argument types using your app sign-in.
Simple named arguments become flags. Use --args or --args-file for the complete argument object, including records or lists. Use --args-file - to read it from stdin. --watch follows a query. --wait calls a mutation once and follows its declared receipt. If you interrupt the watch or let it time out, use bijection wait <receipt> with the same installation. If the mutation reply is lost, use the recovery command printed when the call started. It submits the original request with the original invocation identity. An application or library can declare positionals in an ordinary function spec. Other readers can still call the function with the same object of named arguments.
If that declaration is mounted at finance.invoices.status, run bijection call finance.invoices.status <invoice>. To support --wait, declare a mutation’s completion query. The query takes one argument named receipt of the mutation’s declared return type and reports a pending, completed, or refused state. The app persists the request and decides what counts as completion. The installation returns one opaque receipt that carries the original observer and the launch read floor.

Write a typed client

In the same repository, a frontend imports the app type and calls api<typeof App>(). For a consumer in another repository or language, write a client package from the app’s exposed tree:
ts writes an npm package whose connect(url, options) pins the app contract of the committed bijection.lock. A deployment whose contract differs refuses the client’s calls with Conflict. json writes the language-neutral interface document. See Publish a typed client.

Set a secret

A secret() declared in the tree is named by its path. Only performers open it; no function, command or console shows its value. Set it as an operator, from piped stdin or a private file:
path/member sets one member’s value of a secret({ under: family }). Setting a path again rotates its value. bijection secret list lists the secrets, never their values. A mounted app’s secrets are paths of the installer’s tree, such as payments.provider.key for an app mounted at payments. Its installation guide names the secrets to set.