Workspaces

GET /public/v1/workspaces

List all workspaces the API key can access. Keys are user-scoped: a workspace appears if the key's user is a member of it, or if it has been explicitly granted to them via /public/v1/workspace-grants. Granted-only workspaces report access: "grant".

GET /public/v1/workspaces

GET /public/v1/workspaces

curl --request GET \
  --url 'https://api.joinvalley.co/public/v1/workspaces' \
  --header 'Authorization: Bearer YOUR_SECRET_TOKEN'
{
  "statusCode": 1,
  "status": true,
  "message": "<string>",
  "data": {
    "workspaces": [
      {
        "id": "<string>",
        "name": "<string>",
        "role": "<string>",
        "access": "member",
        "created_at": "<string>"
      }
    ],
    "pagination": {
      "limit": 1,
      "offset": 1,
      "total": 1,
      "hasMore": true
    }
  }
}

Default Response

Authorizations

  • x-api-key string required header

    Your Valley API key.

Query Parameters

  • limit number
  • offset number

    Number of records to skip. Capped at 1,000.

Response

application/json
  • statusCode number
  • status boolean
  • message string
  • data object
    + Show Child Attributes
    • workspaces[] object array
      + Show Child Attributes
      • id string
      • name string
      • role string
      • access string enum enum

        Allowed values: member, grant.

      • created_at string
    • pagination object
      + Show Child Attributes
      • limit number
      • offset number
      • total number
      • hasMore boolean