CI
Read AutoPilot for CI settings
Returns the settings set at this scope (organization when repository is empty, a repository, or one workflow) and the effective settings after inheritance, with the scope each effective value comes from. An organization that turns AutoPilot off or pauses it stops routing everywhere; allowed providers narrow at every scope; the narrowest policy wins.
GET
/
api
/
v1
/
tenant
/
ci
/
autopilot
/
settings
Read AutoPilot for CI settings
curl --request GET \
--url https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings \
--header 'Authorization: <api-key>' \
--header 'X-CostGraph-Tenant-ID: <x-costgraph-tenant-id>'import requests
url = "https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings"
headers = {
"X-CostGraph-Tenant-ID": "<x-costgraph-tenant-id>",
"Authorization": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-CostGraph-Tenant-ID': '<x-costgraph-tenant-id>', Authorization: '<api-key>'}
};
fetch('https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings', 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://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"X-CostGraph-Tenant-ID: <x-costgraph-tenant-id>"
],
]);
$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://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
req.Header.Add("Authorization", "<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://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings")
.header("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-CostGraph-Tenant-ID"] = '<x-costgraph-tenant-id>'
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"message": "some message",
"status": "success",
"data": {
"effective": {
"allow_gpu": true,
"allowed_arch": [
"<string>"
],
"allowed_os": [
"<string>"
],
"allowed_providers": [
"<string>"
],
"enabled": true,
"max_cores": 123,
"paused_until": "<string>",
"policy": "cheapest",
"release": true
},
"inherited_from": {},
"own": {
"allow_gpu": true,
"allowed_arch": [
"<string>"
],
"allowed_os": [
"<string>"
],
"allowed_providers": [
"<string>"
],
"enabled": true,
"max_cores": 123,
"paused_until": "<string>",
"policy": "cheapest",
"release": true
},
"repository": "<string>",
"workflow_path": "<string>"
}
}{
"message": "some message",
"status": "error"
}Authorizations
Enter "Bearer {token}"
Headers
Tenant ID
Query Parameters
owner/name; empty for the organization
Workflow file, such as .github/workflows/ci.yml
Was this page helpful?
⌘I
Read AutoPilot for CI settings
curl --request GET \
--url https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings \
--header 'Authorization: <api-key>' \
--header 'X-CostGraph-Tenant-ID: <x-costgraph-tenant-id>'import requests
url = "https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings"
headers = {
"X-CostGraph-Tenant-ID": "<x-costgraph-tenant-id>",
"Authorization": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-CostGraph-Tenant-ID': '<x-costgraph-tenant-id>', Authorization: '<api-key>'}
};
fetch('https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings', 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://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"X-CostGraph-Tenant-ID: <x-costgraph-tenant-id>"
],
]);
$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://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
req.Header.Add("Authorization", "<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://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings")
.header("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.costgraph.ai/api/v1/tenant/ci/autopilot/settings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-CostGraph-Tenant-ID"] = '<x-costgraph-tenant-id>'
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"message": "some message",
"status": "success",
"data": {
"effective": {
"allow_gpu": true,
"allowed_arch": [
"<string>"
],
"allowed_os": [
"<string>"
],
"allowed_providers": [
"<string>"
],
"enabled": true,
"max_cores": 123,
"paused_until": "<string>",
"policy": "cheapest",
"release": true
},
"inherited_from": {},
"own": {
"allow_gpu": true,
"allowed_arch": [
"<string>"
],
"allowed_os": [
"<string>"
],
"allowed_providers": [
"<string>"
],
"enabled": true,
"max_cores": 123,
"paused_until": "<string>",
"policy": "cheapest",
"release": true
},
"repository": "<string>",
"workflow_path": "<string>"
}
}{
"message": "some message",
"status": "error"
}