curl --request GET \
--url 'https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY='import requests
url = "https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY="
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY=', 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.example.com/ai/device/{device_id}?HAIQU_API_KEY=",
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://api.example.com/ai/device/{device_id}?HAIQU_API_KEY="
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://api.example.com/ai/device/{device_id}?HAIQU_API_KEY=")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY=")
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{
"id": "<string>",
"vendor": "<string>",
"name": "<string>",
"qubits": 123,
"status": "<string>",
"pending_jobs": 123,
"simulator": true,
"last_updated": "2023-11-07T05:31:56Z",
"operation_names": [
"<string>"
],
"coupling_map": [
[
123
]
],
"coupling_map_edges": 123
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Get Device Details
Get one backend with its basis gates and qubit connectivity.
Use this tool when a workflow needs the hardware constraints of a specific
backend rather than the whole catalog: which gates it supports and which
qubit pairs are physically coupled. Those constraints determine what
transpile_circuits can target.
When to Use:
- Call this after
list_qpus_and_simulatorshas narrowed the choice to onedevice_id. - Call this before transpiling or before explaining why a circuit needs routing on a given backend.
Constraints:
operation_namesandcoupling_maparenullfor backends that publish no transpilation target, which is common for simulators.statusandpending_jobsare point-in-time snapshots.
Notes:
coupling_mapcan hold hundreds of qubit pairs on large QPUs. Checkcoupling_map_edgesfirst and summarize connectivity instead of pasting the full list into agent-facing output.
Args:
device_id: Backend identifier returned by list_qpus_and_simulators.
user: Authenticated user resolved from the API key.
db: Active database session.
Returns: The backend record extended with basis gates and coupling map.
Raises:
HTTPException: Raised with 404 when no backend matches device_id.
curl --request GET \
--url 'https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY='import requests
url = "https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY="
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY=', 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.example.com/ai/device/{device_id}?HAIQU_API_KEY=",
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://api.example.com/ai/device/{device_id}?HAIQU_API_KEY="
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://api.example.com/ai/device/{device_id}?HAIQU_API_KEY=")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/ai/device/{device_id}?HAIQU_API_KEY=")
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{
"id": "<string>",
"vendor": "<string>",
"name": "<string>",
"qubits": 123,
"status": "<string>",
"pending_jobs": 123,
"simulator": true,
"last_updated": "2023-11-07T05:31:56Z",
"operation_names": [
"<string>"
],
"coupling_map": [
[
123
]
],
"coupling_map_edges": 123
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Path Parameters
Response
Successful Response
Extend the device catalog entry with transpilation-relevant topology.
Attributes:
last_updated: Timestamp of the last catalog refresh for this backend.
operation_names: Basis gates and instructions the backend supports.
coupling_map: Directed qubit pairs supporting two-qubit operations.
coupling_map_edges: Number of entries in coupling_map, provided so
callers can judge topology size before expanding the full list.