Skip to content

Workspaces

Workspaces are logical groupings of repositories. Use them to organize repositories by team, product, or service area.

{
"id": "w_xxxx",
"name": "Backend Services",
"description": "Core backend microservices",
"repo_count": 5,
"created_at": "2024-01-01T00:00:00Z",
"updated_at": "2024-01-01T00:00:00Z"
}
Field Type Description
id string Unique workspace identifier
name string Display name of the workspace
description string Optional description
repo_count integer Number of repositories in the workspace
created_at string ISO 8601 creation timestamp
updated_at string ISO 8601 last-updated timestamp
POST /v1/workspaces

Creates a new workspace within your tenant.

{
"name": "Backend Services",
"description": "Core backend microservices"
}
Field Type Required Description
name string Yes Display name of the workspace
description string No Optional description

Returns 201 Created with the workspace object.

Terminal window
curl -X POST https://api.intellirag.io/v1/workspaces \
-H "Authorization: Bearer rag_xxxx" \
-H "Content-Type: application/json" \
-d '{"name": "Backend Services", "description": "Core backend microservices"}'
GET /v1/workspaces

Returns a paginated list of workspaces in your tenant.

Parameter Type Default Description
cursor string - Pagination cursor from a previous response
limit integer 50 Number of items per page (max 100)
{
"items": [
{
"id": "w_xxxx",
"name": "Backend Services",
"description": "Core backend microservices",
"repo_count": 5,
"created_at": "2024-01-01T00:00:00Z",
"updated_at": "2024-01-01T00:00:00Z"
}
],
"next_cursor": "eyJ...",
"has_more": true
}
Terminal window
curl https://api.intellirag.io/v1/workspaces?limit=10 \
-H "Authorization: Bearer rag_xxxx"
GET /v1/workspaces/{workspace_id}

Returns a single workspace by ID.

Parameter Type Description
workspace_id string The workspace ID

Returns 200 OK with the workspace object.

Terminal window
curl https://api.intellirag.io/v1/workspaces/w_xxxx \
-H "Authorization: Bearer rag_xxxx"
PATCH /v1/workspaces/{workspace_id}

Updates an existing workspace. Only include the fields you want to change.

Parameter Type Description
workspace_id string The workspace ID
{
"name": "Updated Name"
}
Field Type Required Description
name string No New display name
description string No New description

Returns 200 OK with the updated workspace object.

Terminal window
curl -X PATCH https://api.intellirag.io/v1/workspaces/w_xxxx \
-H "Authorization: Bearer rag_xxxx" \
-H "Content-Type: application/json" \
-d '{"name": "Updated Name"}'
DELETE /v1/workspaces/{workspace_id}

Deletes a workspace and all repositories and indexed data within it. This action is irreversible.

Parameter Type Description
workspace_id string The workspace ID

Returns 204 No Content on success.

Terminal window
curl -X DELETE https://api.intellirag.io/v1/workspaces/w_xxxx \
-H "Authorization: Bearer rag_xxxx"