Get Offer Status
curl --request GET \
--url https://supply-api.compute-desk.com/offers/{offer_id}/status \
--header 'Authorization: Bearer <token>'import requests
url = "https://supply-api.compute-desk.com/offers/{offer_id}/status"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://supply-api.compute-desk.com/offers/{offer_id}/status', 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://supply-api.compute-desk.com/offers/{offer_id}/status",
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://supply-api.compute-desk.com/offers/{offer_id}/status"
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://supply-api.compute-desk.com/offers/{offer_id}/status")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://supply-api.compute-desk.com/offers/{offer_id}/status")
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{
"offer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"procurement_status": "<string>",
"instances": [
{
"instance_id": "<string>",
"instance_name": "<string>",
"zone": "<string>",
"status": "<string>",
"external_ip": "<string>",
"internal_ip": "<string>",
"ssh_command": "<string>"
}
],
"resources": [
{
"resource_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"resource_type": "<string>",
"role": "<string>",
"status": "<string>"
}
],
"progress": "<string>",
"failure_reason": "<string>",
"procured_at": "2023-11-07T05:31:56Z"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Offers
Get Offer Status
Get procurement status and instance details for an offer.
This endpoint checks the real-time status of provisioned instances.
GET
/
offers
/
{offer_id}
/
status
Get Offer Status
curl --request GET \
--url https://supply-api.compute-desk.com/offers/{offer_id}/status \
--header 'Authorization: Bearer <token>'import requests
url = "https://supply-api.compute-desk.com/offers/{offer_id}/status"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://supply-api.compute-desk.com/offers/{offer_id}/status', 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://supply-api.compute-desk.com/offers/{offer_id}/status",
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://supply-api.compute-desk.com/offers/{offer_id}/status"
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://supply-api.compute-desk.com/offers/{offer_id}/status")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://supply-api.compute-desk.com/offers/{offer_id}/status")
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{
"offer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"procurement_status": "<string>",
"instances": [
{
"instance_id": "<string>",
"instance_name": "<string>",
"zone": "<string>",
"status": "<string>",
"external_ip": "<string>",
"internal_ip": "<string>",
"ssh_command": "<string>"
}
],
"resources": [
{
"resource_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"resource_type": "<string>",
"role": "<string>",
"status": "<string>"
}
],
"progress": "<string>",
"failure_reason": "<string>",
"procured_at": "2023-11-07T05:31:56Z"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Poll this endpoint after procurement to check instance readiness.
When
Procurement status values
| Status | Meaning |
|---|---|
available | Offer exists but not yet procured |
provisioning_started | Procurement initiated, vendor provisioning in progress |
provisioning_in_progress | Vendor is creating the instance |
ready | Instance is active — check instances array for connection details |
failed | Procurement failed — check failure_reason |
Polling pattern
# Poll every 15 seconds until ready
while true; do
STATUS=$(curl -s https://supply-api.compute-desk.com/offers/$OFFER_ID/status \
-H "Authorization: Bearer $TOKEN" | jq -r '.procurement_status')
echo "Status: $STATUS"
[ "$STATUS" = "ready" ] && break
[ "$STATUS" = "failed" ] && echo "FAILED" && break
sleep 15
done
procurement_status is ready, the instances array contains:
external_ip— Public IP addressssh_command— Ready-to-use SSH command (e.g.,ssh root@1.2.3.4)status— Instance status (usuallyrunning)
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Response
Successful Response
Status of an offer and its provisioned instances.
Unique offer identifier
Offer status: available, procured, failed, or expired
When this offer was created
Procurement status: pending, provisioning, ready, or failed
Provisioned instances (empty until procurement starts)
Show child attributes
Show child attributes
Resources created by this offer
Show child attributes
Show child attributes
Human-readable progress (e.g. '2/4 instances running')
Reason for failure (present when status=failed)
When this offer was procured (null if not yet procured)