Skip to main content
POST
/
api
/
v1
/
provisioning
/
tenants
/
{tenantId}
/
{collection}
/
{docId}
Create or replace a provisioning document (POST = replace)
curl --request POST \
  --url https://platform.crescendo.ai/api/v1/provisioning/tenants/{tenantId}/{collection}/{docId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{}'
{}
POST requests replace the document at the target path:
  • If the document does not exist, the API returns 201 Created
  • If the document exists, the API returns 200 OK and the previous document content is replaced
The API stamps updated (epoch millis) and updatedBy automatically.

Example: create a user

export CRESCENDO_TENANT_ID="tenant-alpha"
export CRESCENDO_API_KEY="YOUR_API_KEY"

curl -sS -X POST \
  -H "Authorization: Bearer $CRESCENDO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"email":"new.user@example.com","role":"viewer"}' \
  "https://platform.crescendo.ai/api/v1/provisioning/tenants/$CRESCENDO_TENANT_ID/users/user-123"

Example: write a versioned resource

For versioned resources, you can include versions.current in the payload:
curl -sS -X POST \
  -H "Authorization: Bearer $CRESCENDO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"Support Bot","versions":{"current":{"spec":{"greeting":"hello"}}}}' \
  "https://platform.crescendo.ai/api/v1/provisioning/tenants/$CRESCENDO_TENANT_ID/bots/bot-002"

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

tenantId
string
required

Tenant identifier.

collection
string
required

Collection name under the tenant (for example: users, bots, jobs).

docId
string
required

Document identifier within the collection.

Body

application/json

Arbitrary JSON object representing the provisioning resource.

Response

Replaced (existing document)

Arbitrary JSON object representing the provisioning resource.