Orishare
Api
GET
/organizations
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/organizations"
{  "data": [    {      "id": "string",      "name": "string",      "slug": "string",      "plan": {        "id": "string",        "version": 0      },      "billing_mode": "card",      "ai_drafting_disabled": true,      "version": 0,      "created_at": "string",      "updated_at": "string"    }  ],  "next_cursor": "string",  "has_more": true}
GET
/organizations/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/organizations/string"
{  "id": "string",  "name": "string",  "slug": "string",  "plan": {    "id": "string",    "version": 0  },  "billing_mode": "card",  "ai_drafting_disabled": true,  "version": 0,  "created_at": "string",  "updated_at": "string"}
PATCH
/organizations/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

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

application/json

application/json

curl -X PATCH "https://example.com/organizations/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "id": "string",  "name": "string",  "slug": "string",  "plan": {    "id": "string",    "version": 0  },  "billing_mode": "card",  "ai_drafting_disabled": true,  "version": 0,  "created_at": "string",  "updated_at": "string"}
GET
/projects
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Query Parameters

organization_id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/projects?organization_id=string"
{  "data": [    {      "id": "string",      "organization_id": "string",      "name": "string",      "slug": "string",      "version": 0,      "created_at": "string",      "updated_at": "string"    }  ],  "next_cursor": "string",  "has_more": true}
POST
/projects
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Header Parameters

Idempotency-Key?string

Required by the API on this route (400 idempotency_key_required without it); the official clients generate a UUID when you omit it.

Length1 <= length <= 255

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

application/json

application/json

curl -X POST "https://example.com/projects" \  -H "Content-Type: application/json" \  -d '{    "organization_id": "string",    "name": "string"  }'
{  "id": "string",  "organization_id": "string",  "name": "string",  "slug": "string",  "version": 0,  "created_at": "string",  "updated_at": "string"}
GET
/projects/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/projects/string"
{  "id": "string",  "organization_id": "string",  "name": "string",  "slug": "string",  "version": 0,  "created_at": "string",  "updated_at": "string"}
PATCH
/projects/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

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

application/json

application/json

curl -X PATCH "https://example.com/projects/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "id": "string",  "organization_id": "string",  "name": "string",  "slug": "string",  "version": 0,  "created_at": "string",  "updated_at": "string"}
GET
/projects/{id}/environments
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/projects/string/environments"
{  "data": [    {      "id": "string",      "project_id": "string",      "name": "string",      "runtime_class": "sandbox",      "timezone": "string",      "rules_paused": true,      "version": 0,      "created_at": "string",      "updated_at": "string"    }  ],  "next_cursor": "string",  "has_more": true}
GET
/environments/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/environments/string"
{  "id": "string",  "project_id": "string",  "name": "string",  "runtime_class": "sandbox",  "timezone": "string",  "rules_paused": true,  "version": 0,  "created_at": "string",  "updated_at": "string"}
PATCH
/environments/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

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

application/json

application/json

curl -X PATCH "https://example.com/environments/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "id": "string",  "project_id": "string",  "name": "string",  "runtime_class": "sandbox",  "timezone": "string",  "rules_paused": true,  "version": 0,  "created_at": "string",  "updated_at": "string"}
GET
/environments/{id}/api_keys
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/environments/string/api_keys"
{  "data": [    {      "id": "string",      "environment_id": "string",      "kind": "secret",      "name": "string",      "prefix": "string",      "scopes": [        "string"      ],      "last_used_at": "string",      "revoked_at": "string",      "created_at": "string"    }  ],  "next_cursor": "string",  "has_more": true}
POST
/environments/{id}/api_keys
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Header Parameters

Idempotency-Key?string

Required by the API on this route (400 idempotency_key_required without it); the official clients generate a UUID when you omit it.

Length1 <= length <= 255

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

application/json

application/json

curl -X POST "https://example.com/environments/string/api_keys" \  -H "Content-Type: application/json" \  -d '{    "kind": "secret",    "name": "string"  }'
{  "id": "string",  "environment_id": "string",  "kind": "secret",  "name": "string",  "prefix": "string",  "scopes": [    "string"  ],  "last_used_at": "string",  "revoked_at": "string",  "created_at": "string",  "token": "string",  "organization_id": "string"}
DELETE
/api_keys/{id}
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X DELETE "https://example.com/api_keys/string"
Empty
GET
/environments/{id}/usage
AuthorizationBearer <token>

Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).

In: header

Path Parameters

id*string
Length1 <= length

Query Parameters

period?string
Match^\d{4}-\d{2}$

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/environments/string/usage"
{  "data": [    {      "environment_id": "string",      "period": "string",      "accepted_events": 0,      "active_customers": 0,      "webhook_deliveries": 0,      "ai_drafts": 0,      "sync_evaluations": 0    }  ],  "next_cursor": "string",  "has_more": true}