Skip to content

List organizations

Method

GET https://papi.afi.ai/api/v1/orgs/{org_id}/orgs

Description

List children organizations of the specified parent organization. Root organization and its sub-organizations comprise a hierarchy. Every organization in the hierarchy may own its own tenants and resources.

To list all available organizations, use 'limit' and 'page_token' as query parameters.

Path params
org_id string required

ID of the parent organization to list child organizations for.

Query params
limit int32

Max number of items to return on a single page (default 100).

page_token string

Token from the previous list operation (next_page_token) to continue listing.

curl -X GET \
    -H 'Authorization: {api-key}' \
    https://papi.afi.ai/api/v1/orgs/{org_id}/orgs

Successful response (200) schema
object

OrgsPage is the result of organizations listing.

next_page_token string

Next page token to continue listing operation, i.e. to be set as next request page_token. Empty on last page.

items array of objects

Array of organizations.

object

Org describes organization object.

id string

Unique ID of the organization.

name string

Organization name.

Response example
{
  "next_page_token": "string",
  "items": [
    {
      "id": "string",
      "name": "string"
    }
  ]
}