Get organizations

GET /api/organizations

Get organizations that match the given query with pagination.

Query parameters

  • q string

    The query to filter organizations. It can be a partial ID or name.

    If not provided, all organizations will be returned.

  • Whether to show featured users in the organization. Featured users are randomly selected from the organization members.

    If not provided, featuredUsers will not be included in the response.

  • page integer

    Page number (starts from 1).

    Minimum value is 1. Default value is 1.

  • page_size integer

    Entries per page.

    Minimum value is 1. Default value is 20.

Responses

  • 200 application/json

    A list of organizations.

    Hide response attributes Show response attributes object
    • id string Required

      Minimum length is 1, maximum length is 21.

    • name string Required

      Minimum length is 1, maximum length is 128.

    • description string | null Required

      Maximum length is 256.

    • customData object Required

      arbitrary

    • createdAt number Required
    • featuredUsers array[object]
      Hide featuredUsers attributes Show featuredUsers attributes object
      • id string Required

        Minimum length is 1, maximum length is 12.

      • avatar string | null Required

        Maximum length is 2048.

      • name string | null Required

        Maximum length is 128.

  • 400

    Bad Request

  • 401

    Unauthorized

  • 403

    Forbidden

GET /api/organizations
curl \
 -X GET https://[tenant_id].logto.app/api/organizations
Response examples (200)
[
  {
    "id": "string",
    "name": "string",
    "description": "string",
    "customData": {},
    "createdAt": 42.0,
    "usersCount": 42.0,
    "featuredUsers": [
      {
        "id": "string",
        "avatar": "string",
        "name": "string"
      }
    ]
  }
]