Skip to Content
kosemdocs
ReferenceAPIOrganizations

Create organization

Creates an organization. The caller becomes its first member and owner.

POST
/v1/organizations

Creates an organization. The caller becomes its first member and owner.

Authorization

bearer
headerAuthorizationBearer <token>

An access token, or an API key.

Request Body

application/json
  1. body
displayName?string

Name shown in user interfaces.

Lengthlength <= 100
slug*string

Globally unique, human-readable alias: 6 to 30 lowercase letters, digits or hyphens, starting with a letter. It never changes.

Match^[a-z][a-z0-9-]{4,28}[a-z0-9]$

Response Body

Created

application/json
  1. response
createTime*string

When the organization was created.

Formatdate-time
displayName*string

Name shown in user interfaces.

name*string

Resource name, organizations/{organization_id}. The ID is generated by the server and never changes.

slug*string

Globally unique, human-readable alias. It never changes, so that links to the organization keep working.

state*string

Lifecycle state. An organization whose deletion was requested is purged after a grace period unless it is undeleted.

Value in"ACTIVE""DELETE_REQUESTED"
updateTime*string

When the organization was last updated.

Formatdate-time
Example Request
curl -X POST 'https://api.kosem.ai/v1/organizations' \
  -H 'Content-Type: application/json' \
  -d '{
  "slug": "string"
}'
Example Response
{
  "createTime": "2019-08-24T14:15:22Z",
  "displayName": "string",
  "name": "string",
  "slug": "string",
  "state": "ACTIVE",
  "updateTime": "2019-08-24T14:15:22Z"
}