How to choose which workspace a receipt goes to (workspaceId)

Add workspaceId to a score, evaluate or chat request. The receipt is written to that workspace's chain. Leave it out and ClearRun uses your account's first workspace.

Last updated

Steps

  1. Send the id

    {
      "responseText": "Our API never stores customer data.",
      "workspaceId": "WORKSPACE_ID"
    }
  2. Check where it went

    receipt.workspaceId in the response.

Rules

  • The workspace must be on your account, or you get 403 WORKSPACE_FORBIDDEN with Workspace is not on this account.
  • With no workspace on the account, receipts go to an account-level chain whose id starts with account:. It is exported when you call GET /api/audit/export without workspaceId. Passing an account: id as workspaceId to the export returns 404.

Why use it

Separate chains per project or customer, so each can be checked or exported on its own.