Skip to main content
PATCH
/
v1
/
tenants
/
{tenantId}
Update tenant
curl --request PATCH \
  --url https://api.example.com/v1/tenants/{tenantId} \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "settings": {
    "settings.awsRoleArn": "<string>",
    "settings.awsExternalId": "<string>",
    "settings.awsRegion": "<string>",
    "settings.autoRemediation": true
  }
}
'

Overview

Updates one or more fields on a tenant. Only the fields included in the request body are updated — omitted fields retain their current values. Required role: admin

Path parameters

tenantId
string
required
The unique identifier of the tenant to update. Example: ten_EXAMPLE_01HX9VTPQR3KF8MZ.

Request body

All fields are optional. Include only the fields you want to change.
name
string
The new display name for the tenant.
settings
object
Updated AWS integration settings. Provide only the sub-fields you want to change.
When autoRemediation is enabled, approved remediations execute automatically without requiring manual approval each time. Use with caution — this means AI-generated remediation steps will run against your production infrastructure without an additional human confirmation step.

Response

Returns 200 OK with the full updated tenant object.
{
  "tenantId": "ten_EXAMPLE_01HX9VTPQR3KF8MZ",
  "name": "Acme Corp (Updated)",
  "slug": "acme-corp",
  "status": "active",
  "plan": "pro",
  "createdAt": "2026-01-15T09:30:00Z",
  "settings": {
    "awsRoleArn": "arn:aws:iam::<your-aws-account-id>:role/CauseFlowRoleV2",
    "awsExternalId": "causeflow-ext-id-acme",
    "awsRegion": "us-west-2",
    "autoRemediation": true
  }
}

Error responses

StatusError codeDescription
400validation_errorA field value fails validation
403forbiddenThe authenticated user does not have admin role
404not_foundNo tenant exists with the provided tenantId

Examples

curl https://api.causeflow.ai/v1/tenants/ten_EXAMPLE_01HX9VTPQR3KF8MZ \
  -X PATCH \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Acme Corp (Updated)",
    "settings": {
      "awsRegion": "us-west-2",
      "autoRemediation": true
    }
  }'