Retrieve a single organisation
curl --request GET \
--url https://{tenant}/admin/organisations/{orgID} \
--header 'Admin-Auth: <api-key>'import requests
url = "https://{tenant}/admin/organisations/{orgID}"
headers = {"Admin-Auth": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'Admin-Auth': '<api-key>'}};
fetch('https://{tenant}/admin/organisations/{orgID}', 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://{tenant}/admin/organisations/{orgID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Admin-Auth: <api-key>"
],
]);
$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://{tenant}/admin/organisations/{orgID}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Admin-Auth", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{tenant}/admin/organisations/{orgID}")
.header("Admin-Auth", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{tenant}/admin/organisations/{orgID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Admin-Auth"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"apis": [
{
"api_human_name": "API 2",
"api_id": "5fa2db834e07444f760b7ceb314209fb"
},
{
"api_human_name": "API 1",
"api_id": "7a6ddeca9244448a4233866938a0d6e2"
},
{
"api_human_name": "API 3",
"api_id": "109eacaa50b24b64651a1d4dce8ec385"
}
],
"cname": "my.domain.com",
"cname_enabled": true,
"developer_count": 21,
"developer_quota": 123,
"event_options": {
"key_event": {
"email": "",
"redis": true,
"webhook": ""
},
"key_request_event": {
"email": "",
"redis": false,
"webhook": ""
}
},
"hybrid_enabled": false,
"id": "53ac07777cbb8c2d53000002",
"owner_name": "Test",
"owner_slug": "test",
"ui": {
"default_lang": "",
"designer": {},
"dont_allow_license_management": false,
"dont_allow_license_management_view": false,
"dont_show_admin_sockets": false,
"hide_help": false,
"languages": {},
"login_page": {},
"nav": {},
"portal_section": {},
"uptime": {}
}
}{
"Message": "Not authorised",
"Meta": null,
"Status": "Error"
}{
"Message": "Could not retrieve org detail",
"Meta": null,
"Status": "Error"
}{
"Message": "Failed to marshal org data from DB",
"Meta": null,
"Status": "Error"
}Organisations
Retrieve a single organisation
Retrieve a single organisation
GET
/
admin
/
organisations
/
{orgID}
Retrieve a single organisation
curl --request GET \
--url https://{tenant}/admin/organisations/{orgID} \
--header 'Admin-Auth: <api-key>'import requests
url = "https://{tenant}/admin/organisations/{orgID}"
headers = {"Admin-Auth": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'Admin-Auth': '<api-key>'}};
fetch('https://{tenant}/admin/organisations/{orgID}', 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://{tenant}/admin/organisations/{orgID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Admin-Auth: <api-key>"
],
]);
$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://{tenant}/admin/organisations/{orgID}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Admin-Auth", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{tenant}/admin/organisations/{orgID}")
.header("Admin-Auth", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{tenant}/admin/organisations/{orgID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Admin-Auth"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"apis": [
{
"api_human_name": "API 2",
"api_id": "5fa2db834e07444f760b7ceb314209fb"
},
{
"api_human_name": "API 1",
"api_id": "7a6ddeca9244448a4233866938a0d6e2"
},
{
"api_human_name": "API 3",
"api_id": "109eacaa50b24b64651a1d4dce8ec385"
}
],
"cname": "my.domain.com",
"cname_enabled": true,
"developer_count": 21,
"developer_quota": 123,
"event_options": {
"key_event": {
"email": "",
"redis": true,
"webhook": ""
},
"key_request_event": {
"email": "",
"redis": false,
"webhook": ""
}
},
"hybrid_enabled": false,
"id": "53ac07777cbb8c2d53000002",
"owner_name": "Test",
"owner_slug": "test",
"ui": {
"default_lang": "",
"designer": {},
"dont_allow_license_management": false,
"dont_allow_license_management_view": false,
"dont_show_admin_sockets": false,
"hide_help": false,
"languages": {},
"login_page": {},
"nav": {},
"portal_section": {},
"uptime": {}
}
}{
"Message": "Not authorised",
"Meta": null,
"Status": "Error"
}{
"Message": "Could not retrieve org detail",
"Meta": null,
"Status": "Error"
}{
"Message": "Failed to marshal org data from DB",
"Meta": null,
"Status": "Error"
}Response
Organisation retrieved
Was this page helpful?