Skip to main content
SONZAI
Api

User Personas

List user personas

GET
/user-personas

Authorization

bearerClerk
AuthorizationBearer <token>

Clerk session JWT from an authenticated dashboard user. Format: Bearer eyJ....

In: header

Response Body

application/json

application/problem+json

curl -X GET "https://loading/api/v1/user-personas"
{
  "$schema": "/api/v1/schemas/ListUserPersonasOutputBody.json",
  "personas": [
    {
      "$schema": "/api/v1/schemas/UserPersonaRecord.json",
      "created_at": "2019-08-24T14:15:22Z",
      "description": "string",
      "is_default": true,
      "name": "string",
      "persona_id": "string",
      "style": "string",
      "tenant_id": "string",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}
{
  "$schema": "/api/v1/schemas/ErrorModel.json",
  "detail": "Property foo is required but is missing.",
  "errors": [
    {
      "location": "string",
      "message": "string",
      "value": null
    }
  ],
  "instance": "https://example.com/error-log/abc123",
  "status": 400,
  "title": "Bad Request",
  "type": "https://example.com/errors/example"
}

Create a user persona

POST
/user-personas

Authorization

bearerClerk
AuthorizationBearer <token>

Clerk session JWT from an authenticated dashboard user. Format: Bearer eyJ....

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/problem+json

curl -X POST "https://loading/api/v1/user-personas" \  -H "Content-Type: application/json" \  -d '{    "name": "string"  }'
{
  "$schema": "/api/v1/schemas/UserPersonaRecord.json",
  "created_at": "2019-08-24T14:15:22Z",
  "description": "string",
  "is_default": true,
  "name": "string",
  "persona_id": "string",
  "style": "string",
  "tenant_id": "string",
  "updated_at": "2019-08-24T14:15:22Z"
}
{
  "$schema": "/api/v1/schemas/ErrorModel.json",
  "detail": "Property foo is required but is missing.",
  "errors": [
    {
      "location": "string",
      "message": "string",
      "value": null
    }
  ],
  "instance": "https://example.com/error-log/abc123",
  "status": 400,
  "title": "Bad Request",
  "type": "https://example.com/errors/example"
}

Get a user persona

GET
/user-personas/{personaId}

Authorization

bearerClerk
AuthorizationBearer <token>

Clerk session JWT from an authenticated dashboard user. Format: Bearer eyJ....

In: header

Path Parameters

personaId*string

Persona UUID

Response Body

application/json

application/problem+json

curl -X GET "https://loading/api/v1/user-personas/string"
{
  "$schema": "/api/v1/schemas/UserPersonaRecord.json",
  "created_at": "2019-08-24T14:15:22Z",
  "description": "string",
  "is_default": true,
  "name": "string",
  "persona_id": "string",
  "style": "string",
  "tenant_id": "string",
  "updated_at": "2019-08-24T14:15:22Z"
}
{
  "$schema": "/api/v1/schemas/ErrorModel.json",
  "detail": "Property foo is required but is missing.",
  "errors": [
    {
      "location": "string",
      "message": "string",
      "value": null
    }
  ],
  "instance": "https://example.com/error-log/abc123",
  "status": 400,
  "title": "Bad Request",
  "type": "https://example.com/errors/example"
}

Delete a user persona

DELETE
/user-personas/{personaId}

Authorization

bearerClerk
AuthorizationBearer <token>

Clerk session JWT from an authenticated dashboard user. Format: Bearer eyJ....

In: header

Path Parameters

personaId*string

Persona UUID

Response Body

application/json

application/problem+json

curl -X DELETE "https://loading/api/v1/user-personas/string"
{
  "$schema": "/api/v1/schemas/DeleteUserPersonaOutputBody.json",
  "success": true
}
{
  "$schema": "/api/v1/schemas/ErrorModel.json",
  "detail": "Property foo is required but is missing.",
  "errors": [
    {
      "location": "string",
      "message": "string",
      "value": null
    }
  ],
  "instance": "https://example.com/error-log/abc123",
  "status": 400,
  "title": "Bad Request",
  "type": "https://example.com/errors/example"
}

Update a user persona

PUT
/user-personas/{personaId}

Authorization

bearerClerk
AuthorizationBearer <token>

Clerk session JWT from an authenticated dashboard user. Format: Bearer eyJ....

In: header

Path Parameters

personaId*string

Persona UUID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/problem+json

curl -X PUT "https://loading/api/v1/user-personas/string" \  -H "Content-Type: application/json" \  -d '{}'
{
  "$schema": "/api/v1/schemas/UserPersonaRecord.json",
  "created_at": "2019-08-24T14:15:22Z",
  "description": "string",
  "is_default": true,
  "name": "string",
  "persona_id": "string",
  "style": "string",
  "tenant_id": "string",
  "updated_at": "2019-08-24T14:15:22Z"
}
{
  "$schema": "/api/v1/schemas/ErrorModel.json",
  "detail": "Property foo is required but is missing.",
  "errors": [
    {
      "location": "string",
      "message": "string",
      "value": null
    }
  ],
  "instance": "https://example.com/error-log/abc123",
  "status": 400,
  "title": "Bad Request",
  "type": "https://example.com/errors/example"
}