Get available organizations

GET /organizations

Get organizations the current user can assign users to, filtered by business hierarchy

Responses

  • 200 application/json

    Organizations retrieved successfully

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object
      Hide data attribute Show data attribute object
      • organizations array[object]
        Hide organizations attributes Show organizations attributes object
        • id string

          Organization ID

        • name string

          Organization name

        • description string

          Organization description

        • type string

          Organization type

          Values are owner, distributor, reseller, or customer.

        • branding object
          Hide branding attributes Show branding attributes object
          • logo_url string

            Organization logo URL

          • dark_logo_url string

            Organization dark theme logo URL

  • 401 application/json

    Unauthorized - invalid or missing token

    Hide response attributes Show response attributes object
    • code integer
    • message string
    • data object | null
GET /organizations
curl \
 --request GET 'https://api.your-domain.com/api/organizations' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "code": 200,
  "message": "organizations retrieved successfully",
  "data": {
    "organizations": [
      {
        "id": "org_123456789",
        "name": "ACME Corp",
        "description": "Main customer organization",
        "type": "customer",
        "branding": {
          "logo_url": "https://cdn.example.com/logos/org-console.png",
          "dark_logo_url": "https://cdn.example.com/logos/org-console-dark.png"
        }
      }
    ]
  }
}
Response examples (401)
{
  "code": 401,
  "message": "invalid token",
  "data": {}
}