These examples describe the current Bijection CLI and SDK source. Use builds
from the same source commit for these APIs. The public CLI and npm SDK
are published independently and may lag this reference.
Application map
Prepare and run
Deploy against a service that implements the committed contract. The example holds the contract and its receiver, not a running CRM. Set the receiver’s credential once:associate answers the customer’s key; use it as CUSTOMER_ID. rename
commits the requested name and one renameCustomer task together, with
once set to the customer, the revision read and the name, so asking again
sends nothing more. The receiver’s contract is keyed: a send whose answer
was lost is resent under the same Idempotency-Key, and the CRM answers
with the original rename.
Read the result correctly
requested_name is the name a writer asked for, and rename.status is how
the CRM answered, recorded by the continuation customers.renamed:
applied, conflict (the account moved: read it again and retry),
pending, rejected, unknown or failed. A refused task keeps its
code and message in rename.refusal. Display it using refusalText from
@bijectionhq/bijection/client. observed_name changes only
when the feed reads the account back, so a concurrent change in the CRM
may differ from the request.
To explore privately, stage changes in a branch: tasks staged
there are never performed. Discard the branch when you are done.