List child organizations
Lists child organizations. Requires an admin of the parent or an ancestor. See Create a child organization.
GET
/
api
/
v1
/
orgs
/
{org}
/
orgs
List child organizations
curl --request GET \
--url https://auth.cognite.com/api/v1/orgs/{org}/orgsimport requests
url = "https://auth.cognite.com/api/v1/orgs/{org}/orgs"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://auth.cognite.com/api/v1/orgs/{org}/orgs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://auth.cognite.com/api/v1/orgs/{org}/orgs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://auth.cognite.com/api/v1/orgs/{org}/orgs"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://auth.cognite.com/api/v1/orgs/{org}/orgs")
.asString();require 'uri'
require 'net/http'
url = URI("https://auth.cognite.com/api/v1/orgs/{org}/orgs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"items": [
{
"id": "my-org",
"parentId": "my-org",
"idp": {
"idpVendor": "AZURE_AD",
"issuer": "https://login.microsoftonline.com/some-tenant-id/v2.0"
},
"adminsCanCreateOrgsInSubtree": false,
"adminsCanCreateProjectsInSubtree": false,
"allowedClusters": [
"westeurope-1",
"asia-northeast1-1"
],
"migrationStatus": "EXCLUSIVE_LOGIN",
"adminGroupId": "my-external-group",
"isDeleted": false,
"profilesEnabled": true
}
],
"nextCursor": "<string>"
}Path Parameters
ID of an organization The ID of an organization
Required string length:
3 - 64Pattern:
^([a-z][a-z0-9-]{1,62}[a-z0-9])$Example:
"my-org"
⌘I
List child organizations
curl --request GET \
--url https://auth.cognite.com/api/v1/orgs/{org}/orgsimport requests
url = "https://auth.cognite.com/api/v1/orgs/{org}/orgs"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://auth.cognite.com/api/v1/orgs/{org}/orgs', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://auth.cognite.com/api/v1/orgs/{org}/orgs",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://auth.cognite.com/api/v1/orgs/{org}/orgs"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://auth.cognite.com/api/v1/orgs/{org}/orgs")
.asString();require 'uri'
require 'net/http'
url = URI("https://auth.cognite.com/api/v1/orgs/{org}/orgs")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"items": [
{
"id": "my-org",
"parentId": "my-org",
"idp": {
"idpVendor": "AZURE_AD",
"issuer": "https://login.microsoftonline.com/some-tenant-id/v2.0"
},
"adminsCanCreateOrgsInSubtree": false,
"adminsCanCreateProjectsInSubtree": false,
"allowedClusters": [
"westeurope-1",
"asia-northeast1-1"
],
"migrationStatus": "EXCLUSIVE_LOGIN",
"adminGroupId": "my-external-group",
"isDeleted": false,
"profilesEnabled": true
}
],
"nextCursor": "<string>"
}