curl "https://api.ionq.co/v0.3/report/organizations/c0a04808-8914-4fcc-9a1e-79b1d9370b85?start_date=2023-07-01&end_date=2023-07-31" \
-H "Authorization: apiKey your-api-key"import requests
url = "https://api.ionq.co/v0.3/report/organizations/{org_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.ionq.co/v0.3/report/organizations/{org_id}', 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.ionq.co/v0.3/report/organizations/{org_id}",
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: Bearer <token>"
],
]);
$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.ionq.co/v0.3/report/organizations/{org_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.ionq.co/v0.3/report/organizations/{org_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ionq.co/v0.3/report/organizations/{org_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"start_date": "2023-07-01",
"end_date": "2023-07-31",
"organization": "Arboreal Research Division",
"organization_id": "71d164e-6ebe-4126-8839-f1529bb01a00",
"budget": 150000,
"balance": 47500,
"currency": "USD",
"qpus": [
{
"qpu_name": "qpu.harmony",
"usage": 1500
}
],
"members": [
{
"id": "64dd217730fd9d001c38fa6a",
"jobs": 3,
"user_email": "[email protected]",
"first_name": "Sammy",
"last_name": "Davis Jr.",
"execution_time": 1200,
"quota": 250,
"quota_consumed": 45
}
]
}Get an Organization’s Report
Get a usage report for the given organization from the start_date and end_date, detailing how much usage went to each QPU during that period. If no start_date or end_date are provided, period defaults to last 30 days until current time.
curl "https://api.ionq.co/v0.3/report/organizations/c0a04808-8914-4fcc-9a1e-79b1d9370b85?start_date=2023-07-01&end_date=2023-07-31" \
-H "Authorization: apiKey your-api-key"import requests
url = "https://api.ionq.co/v0.3/report/organizations/{org_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.ionq.co/v0.3/report/organizations/{org_id}', 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.ionq.co/v0.3/report/organizations/{org_id}",
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: Bearer <token>"
],
]);
$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.ionq.co/v0.3/report/organizations/{org_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.ionq.co/v0.3/report/organizations/{org_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ionq.co/v0.3/report/organizations/{org_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"start_date": "2023-07-01",
"end_date": "2023-07-31",
"organization": "Arboreal Research Division",
"organization_id": "71d164e-6ebe-4126-8839-f1529bb01a00",
"budget": 150000,
"balance": 47500,
"currency": "USD",
"qpus": [
{
"qpu_name": "qpu.harmony",
"usage": 1500
}
],
"members": [
{
"id": "64dd217730fd9d001c38fa6a",
"jobs": 3,
"user_email": "[email protected]",
"first_name": "Sammy",
"last_name": "Davis Jr.",
"execution_time": 1200,
"quota": 250,
"quota_consumed": 45
}
]
}Path Parameters
The UUID of the organization — this UUID is provided in the response on organization creation.
Query Parameters
The start date of report.
"2023-07-01"
The end date of report.
"2023-07-31"
Response
Successfully retrieved a report of an organization.
Organizational report.
Start date.
"2023-07-01"
End date.
"2023-07-31"
Organization name.
"Arboreal Research Division"
UUID of an organization.
"71d164e-6ebe-4126-8839-f1529bb01a00"
Organization quota limit.
150000
Organization balance.
47500
Organization currency. ACU is used instead of USD for organizations with jobs billed in Credits.
"USD"
Show child attributes
Show child attributes
A list of user reports.
Show child attributes
Show child attributes
Was this page helpful?

