Skip to main content
POST
/
workspaces
/
create
Create Workspace
curl --request POST \
  --url https://api.raydocs.com/workspaces/create \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "My Project",
  "icon": "📊"
}
'
{
  "id": 123,
  "name": "<string>",
  "icon": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}

Authentication & Scope

Requires the workspaces-write ability.

Request

POST /workspaces/create HTTP/1.1
Host: api.raydocs.com
Authorization: Bearer <token>
Content-Type: application/json

{
  "name": "New Workspace",
  "icon": "🚀"
}

Body Parameters

ParameterTypeRequiredDescription
namestringYesName of the workspace
iconstringNoEmoji or icon for the workspace

Response

201 Created – The newly created workspace.
{
  "id": 2,
  "name": "New Workspace",
  "icon": "🚀",
  "settings": {},
  "created_at": "2024-01-15T10:30:00Z",
  "updated_at": "2024-01-15T10:30:00Z"
}
422 Unprocessable Entity – Validation error.

Authorizations

Authorization
string
header
required

Personal Access Token

Body

application/json
name
string
required

Workspace name

Example:

"My Project"

icon
string

Emoji or icon

Example:

"📊"

Response

Created

id
integer
name
string
icon
string
created_at
string<date-time>
updated_at
string<date-time>