Integrations
List CI runner spend per GitHub organization
Lists CI runner spend per GitHub organization this month and whether each runner vendor is estimated from GitHub or billed by its own connection.
GET
/
api
/
v1
/
integrations
/
ci-runners
List CI runner spend per GitHub organization
curl --request GET \
--url https://api.costgraph.ai/api/v1/integrations/ci-runners \
--header 'X-CostGraph-Tenant-ID: <x-costgraph-tenant-id>'import requests
url = "https://api.costgraph.ai/api/v1/integrations/ci-runners"
headers = {"X-CostGraph-Tenant-ID": "<x-costgraph-tenant-id>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-CostGraph-Tenant-ID': '<x-costgraph-tenant-id>'}};
fetch('https://api.costgraph.ai/api/v1/integrations/ci-runners', 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/integrations/ci-runners",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"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/integrations/ci-runners"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
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/integrations/ci-runners")
.header("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.costgraph.ai/api/v1/integrations/ci-runners")
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>'
response = http.request(request)
puts response.read_body{
"message": "some message",
"status": "success",
"data": {
"github": [
{
"connection_id": "<string>",
"organization": "<string>",
"vendors": [
{
"billed": true,
"month_to_date": 123,
"name": "<string>",
"slug": "<string>"
}
]
}
],
"vendors": [
{
"connection_id": "<string>",
"name": "<string>",
"slug": "<string>",
"state": "needs_github"
}
]
}
}{
"message": "some message",
"status": "error"
}Was this page helpful?
⌘I
List CI runner spend per GitHub organization
curl --request GET \
--url https://api.costgraph.ai/api/v1/integrations/ci-runners \
--header 'X-CostGraph-Tenant-ID: <x-costgraph-tenant-id>'import requests
url = "https://api.costgraph.ai/api/v1/integrations/ci-runners"
headers = {"X-CostGraph-Tenant-ID": "<x-costgraph-tenant-id>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-CostGraph-Tenant-ID': '<x-costgraph-tenant-id>'}};
fetch('https://api.costgraph.ai/api/v1/integrations/ci-runners', 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/integrations/ci-runners",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"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/integrations/ci-runners"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
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/integrations/ci-runners")
.header("X-CostGraph-Tenant-ID", "<x-costgraph-tenant-id>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.costgraph.ai/api/v1/integrations/ci-runners")
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>'
response = http.request(request)
puts response.read_body{
"message": "some message",
"status": "success",
"data": {
"github": [
{
"connection_id": "<string>",
"organization": "<string>",
"vendors": [
{
"billed": true,
"month_to_date": 123,
"name": "<string>",
"slug": "<string>"
}
]
}
],
"vendors": [
{
"connection_id": "<string>",
"name": "<string>",
"slug": "<string>",
"state": "needs_github"
}
]
}
}{
"message": "some message",
"status": "error"
}