Skip to main content

Get Workspace

Returns the default workspace for the user associated with the API key. Use this to obtain the workspaceId required by other endpoints.

Request

GET /api/trpc/workspace.getDefaultWithApiKey

Headers

HeaderRequiredDescription
AuthorizationYesAPI key in Bearer snorbe_... format

Request Body

None (GET request)

Response

{
  "result": {
    "data": {
      "json": {
        "workspaceId": "cmkt9lpfe000bu95cdrcr2nbt",
        "workspaceName": "My Workspace"
      }
    }
  }
}

Response Fields

FieldTypeDescription
workspaceIdstringWorkspace ID
workspaceNamestringWorkspace name

Examples

curl "https://app.snorbe.com/api/trpc/workspace.getDefaultWithApiKey" \
  -H "Authorization: Bearer snorbe_your_api_key_here"

Error Responses

HTTP StatusCodeDescription
401UNAUTHORIZEDInvalid, expired, or missing API key
429TOO_MANY_REQUESTSRate limit exceeded