View as Markdown

Authorize · API reference

Checkout setup

Set up agent checkout: the setup's step state, and Muse, a test agent for your store.

Related guide: Set up agent checkout

The checkout setup object

Attributes

objectenum
The type of object. One of authorize_setup.
key_createdboolean
The account has an active API key in this environment.
decision_seenboolean
An assessment, or a decision your Identify middleware reported.
webhook_deliveredboolean
An authorize.checkout_approval.* event reached one of your endpoints.
test_agent_runboolean
A test agent checked out with an approval.
webhook_endpointobject | null
The endpoint that gets checkout approval events, when there is one.
Show child attributes
idstring
The endpoint's ID.
urlstring
The endpoint's URL.
latest_test_agent_runobject | any | null
The newest test agent run.
Show child attributes
objectenum
The type of object. One of test_agent_run.
idstring
Unique identifier for the object (tar_…).
statusenum
running while Muse waits for the approval. One of running, done.
resultenum
Once done: Muse checked out with the approval, the person declined, nobody approved within 60 seconds, or the run stopped. One of approved, declined, expired, error, refused.
store_originstring
The store's origin.
checkout_approval_idstring | null
The cart approval the store opened, when it's yours.
stepsarray of objects
What Muse did, in order.
Show child attributes
stepenum
The step. One of load_product, add_to_cart, checkout, relay, wait, retry.
okboolean
Whether it worked.
detailstring
What happened, in a line.
attimestamp
When.
created_attimestamp
When the run started.
finished_attimestamp | null
When it ended.
approve_urlstring
On create: the approve link the store's 401 gave Muse.
status_urlstring
On create: where Muse waits for the outcome.
passkeysobject
What a new passkey needs (your checkout rules' passkeys, or the default).
Show child attributes
new_passkeyenum
The setting. One of step_up_contact, accept, require_existing.
min_passkey_ageinteger
Seconds.
no_contactenum
With no customer contact. One of accept, decline.

The checkout setup object

{
  "object": "authorize_setup",
  "key_created": true,
  "decision_seen": true,
  "webhook_delivered": false,
  "test_agent_run": false,
  "webhook_endpoint": null,
  "latest_test_agent_run": null,
  "passkeys": {
    "new_passkey": "step_up_contact",
    "min_passkey_age": 86400,
    "no_contact": "accept"
  }
}

Retrieve the checkout setup

GET/v1/authorize/setup

The four steps of "Set up agent checkout", each done or not done as the API has seen it: a key, a decision, a delivered confirmation and a test agent's checkout. Also your new-passkey setting. Free.

Parameters

No parameters.

Returns

The setup state. See the checkout setup object.

Errors

export PROVENANCE_KEY=prv_test_ent_E7nT2vQ9bW4mK8sYd3cFjLh6gAe1pR5x
curl "$PROVENANCE_API/v1/authorize/setup" \
  -H "Authorization: Bearer $PROVENANCE_KEY"

Response 200

{
  "object": "authorize_setup",
  "key_created": true,
  "decision_seen": true,
  "webhook_delivered": false,
  "test_agent_run": false,
  "webhook_endpoint": null,
  "latest_test_agent_run": null,
  "passkeys": {
    "new_passkey": "step_up_contact",
    "min_passkey_age": 86400,
    "no_contact": "accept"
  }
}

Send a test agent

POST/v1/authorize/setup/test_agent

Runs Muse, a test agent with no Provenance support, against your store: it checks out, relays the 401's approve_url (here, and by text to notify.phone), waits up to 60 seconds and retries with the token. The result lands on GET /v1/authorize/setup. Sandbox keys only, 5 an hour; store_url must be https and public. Free.

Parameters

store_urlstringRequired
Your store's product page (https).
notifyobject
Text the approve link to this phone as well.
Show child attributes
phonestring
E.164, for example +14155550142.

Returns

The run, with the link Muse relayed.

Errors

export PROVENANCE_KEY=prv_test_ent_E7nT2vQ9bW4mK8sYd3cFjLh6gAe1pR5x
curl -X POST "$PROVENANCE_API/v1/authorize/setup/test_agent" \
  -H "Authorization: Bearer $PROVENANCE_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "store_url": "https://brightbox.example/" }'

Response 201

{
  "object": "test_agent_run",
  "id": "tar_01M6T2Z8W3QK4N7V5B9X1Y2C3D",
  "status": "running",
  "result": null,
  "store_origin": "https://brightbox.example",
  "checkout_approval_id": "coap_01M6T2Z9A1B2C3D4E5F6G7H8J9",
  "steps": [
    {
      "step": "load_product",
      "ok": true,
      "detail": "Loaded /",
      "at": "2026-11-06T18:03:10.112Z"
    },
    {
      "step": "add_to_cart",
      "ok": true,
      "detail": "Added to cart",
      "at": "2026-11-06T18:03:10.240Z"
    },
    {
      "step": "checkout",
      "ok": true,
      "detail": "Ask the person you're shopping for to approve this order: https://app.provenanceauth.com/approve/c/Hq2vN8xK4tB7mW3sYd9cFj. Then retry this request.",
      "at": "2026-11-06T18:03:10.395Z"
    },
    {
      "step": "relay",
      "ok": true,
      "detail": "Relayed the link here",
      "at": "2026-11-06T18:03:10.401Z"
    }
  ],
  "created_at": "2026-11-06T18:03:10.020Z",
  "finished_at": null,
  "approve_url": "https://app.provenanceauth.com/approve/c/Hq2vN8xK4tB7mW3sYd9cFj",
  "status_url": "https://api.provenanceauth.com/v1/authorize/checkout_approvals/requests/status?token=Hq2vN8xK4tB7mW3sYd9cFj"
}

Was this page helpful? Send us feedback

LLM? Read llms.txt.