User Snapshots

Apply a user snapshot

POST
/api/user-snapshots/{id}/apply

Creates a new user in the caller organization and clones the snapshot automations, prompts, and templates (with pipeline-stage and agent mappings) inside a single transaction. Same-org applies skip automations and templates to avoid duplicates.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/api/user-snapshots/string/apply" \  -H "Content-Type: application/json" \  -d '{    "pipelineMapping": {      "Move to Contacted on first reply": {        "Contacted": "Reached Out"      }    },    "agentMapping": {},    "applyAutomations": true,    "applyPrompts": true,    "applyTemplates": true,    "newUser": {      "email": "casey@acme.example",      "password": "TempPass!2026",      "fullName": "Casey New",      "accessRole": "SALES_REP"    }  }'
{  "message": "Snapshot applied",  "result": {    "userId": "64ee9a8b1e7f2a001122339c",    "userEmail": "casey@acme.example",    "cloned": {      "automations": 5,      "prompts": 8,      "templates": 12    },    "mapped": {      "prompts": 0    },    "skipped": {      "automations": 0,      "templates": 0    }  }}