Body
Unique identifier for the parent Organization. This is used to find sub-organizations within it.
Specifies the type of filter to apply, i.e ‘CREDENTIAL_ID’, ‘NAME’, ‘USERNAME’, ‘EMAIL’, ‘PHONE_NUMBER’, ‘OIDC_TOKEN’ or ‘PUBLIC_KEY’
The value of the filter to apply for the specified type. For example, a specific email or name string.
paginationOptions field
A limit of the number of object to be returned, between 1 and 100. Defaults to 10.
A pagination cursor. This is an object ID that enables you to fetch all objects before this ID.
A pagination cursor. This is an object ID that enables you to fetch all objects after this ID.
Response
A successful response returns the following fields:
List of unique identifiers for the matching sub-organizations.
curl --request POST \
--url https://api.turnkey.com/public/v1/query/list_suborgs \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"organizationId": "<string>",
"filterType": "<string>",
"filterValue": "<string>",
"paginationOptions": {
"limit": "<string>",
"before": "<string>",
"after": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_UNKNOWN_V1",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g., 1745474677463)",
"result": {
"organizationIds": [
"<string_element>"
]
}
}
}