List workspaces

OpenAPI contract

Method
GET
Path
/api/v1/workspaces
Security
jwtBearer (bearer)
Response status
200 400 401 403 404 409 429 500
Request and response schemas
JSON
{
  "requestBody": {},
  "responses": {
    "200": {
      "description": "Workspaces",
      "content": {
        "application/json": {
          "items": {
            "$ref": "#/components/schemas/WorkspaceResponse"
          },
          "type": "array"
        }
      }
    },
    "400": {
      "description": "Invalid request",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/RequestError"
        }
      }
    },
    "401": {
      "description": "Authentication required or invalid",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/SecurityError"
        }
      }
    },
    "403": {
      "description": "Authenticated but not permitted",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/SecurityError"
        }
      }
    },
    "404": {
      "description": "Requested workspace resource was not found",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/ApiError"
        }
      }
    },
    "409": {
      "description": "Request conflicts with current workspace state",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/ApiError"
        }
      }
    },
    "429": {
      "description": "Rate limit exceeded",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/SecurityError"
        }
      }
    },
    "500": {
      "description": "Unexpected server error",
      "content": {
        "application/json": {
          "$ref": "#/components/schemas/ApiError"
        }
      }
    }
  }
}

GET /api/v1/workspaces is JWT-only. It returns the workspaces visible to the current account after ensuring that the account has its migrated personal organization and default workspace. includeArchived defaults to false; set it to true to include visible archived workspaces.

Each item includes workspace and organization IDs and names, archive and personal-workspace flags, the caller's effective workspace and organization roles, resolved capabilities, member and project counts, and timestamps. An nfy_ automation key cannot call this operation.

http
GET /api/v1/workspaces?includeArchived=false
Authorization: Bearer <JWT>