MCP / AI
Workspaces MCP Tools

Workspaces MCP Tools

One read-only tool, list_workspaces, gives an AI client (Claude Desktop, Claude Code, or any MCP-speaking assistant) visibility into which workspaces the authenticated user belongs to and their role in each. There is currently no MCP tool to create, update, or delete a workspace, or to manage its membership (invite/list/remove) — use the REST API or the app UI for those.

For the underlying business rules, see Features — Workspaces. This page is based on specs/mcp/workspaces.md in the repo — see that spec for the exact DynamoDB access pattern behind the tool.

list_workspaces

list_workspaces(ctx: Context) -> str

Lists the workspaces the calling (authenticated) user belongs to. Identity comes from the MCP session itself — there's no user_id parameter to pass.

⚠️

Returns a JSON string, not a structured object — parse it before use, same as every other lkwiz_mcp tool.

{
  "workspaces": [
    {
      "workspace_id": "ws_123",
      "name": "Acme Marketing",
      "description": "Q3 content calendar",
      "role": "owner",
      "created_at": "2026-07-17T10:00:00+00:00"
    }
  ]
}

An empty result is a valid, non-error outcome: {"workspaces": []} if the user belongs to none.

Deviations from REST

This tool is implemented independently of workspaces_service (raw boto3 DynamoDB calls, not the shared service layer), so it diverges from GET /api/workspaces in a few concrete ways:

REST APIMCP tool
Fields returnedFull workspace record + member_role, member_countNarrower: workspace_id, name, description, role, created_at
Role field namemember_rolerole
Default role if a membership lookup unexpectedly misses"viewer""member"
Soft-deleted workspace filteringExcluded from the listNot filtered — a workspace whose META item still exists after a soft delete would still show up
Create / update / delete a workspaceFull CRUDNot available
Invite / list / remove membersFull CRUDNot available
⚠️

Because soft-delete filtering isn't applied here, don't rely on this tool to decide whether a workspace is "still active" — cross-check with GET /api/workspaces/{id} if that matters for your use case.

See also