GET /api/v1/hosts/market
Operation: getHostMarket.
Market stats (host): per-GPU-model supply, listed-rate band, fill rate and time-to-first-rental — aggregate only
Our own marketplace, never a competitor’s. Aggregate only: no machine id,
host id, offer id or any individual host’s rate is ever returned — the
only rate values that escape are the p10/median/p90 band of a bucket of
at least min_sample_size listed machines, plus the CALLER’s own median
listed rate (your_rate_micro). Below the threshold a bucket reports its
sample_size with every metric null; a median is never computed from a
handful of observations. median_time_to_first_rental_s has its own
sample gate (rental_sample_size), because a model can be widely listed
and barely rented. Window is half-open UTC [from, to).
Endpoint
Section titled “Endpoint”GET https://amplerun-api.spiry.org/api/v1/hosts/market
Authentication
Section titled “Authentication”Use the credential and scope required by this operation. For programmatic renter/host calls: Authorization: Bearer $AMPLERUN_API_KEY. A host-agent signature or other specialized proof is required where the description specifies it.
Parameters
Section titled “Parameters”| Name | Location | Presence | Type | Description |
|---|---|---|---|---|
gpu_model | query | Optional | string | Exact manifest GPU model to restrict to. |
window | query | Optional | string | Trailing window, e.g. 30d (1..365); anything else is 422. |
Responses
Section titled “Responses”Per-model market aggregates.
application/json
| Field | Type | Presence | Description |
|---|---|---|---|
window_days | integer | Required | |
from | Rfc3339Utc | Required | |
to | Rfc3339Utc | Required | |
min_sample_size | integer | Required | Observations required before any metric is reported. |
models | array of object | Required |
{ "type": "object", "additionalProperties": false, "required": [ "window_days", "from", "to", "min_sample_size", "models" ], "properties": { "window_days": { "type": "integer" }, "from": { "$ref": "#/components/schemas/Rfc3339Utc" }, "to": { "$ref": "#/components/schemas/Rfc3339Utc" }, "min_sample_size": { "type": "integer", "description": "Observations required before any metric is reported." }, "models": { "type": "array", "items": { "type": "object", "additionalProperties": false, "required": [ "gpu_model", "sample_size", "listed_gpus", "allocated_gpus", "utilization_pct", "rate_micro", "fill_rate_pct", "rental_sample_size", "median_time_to_first_rental_s", "your_rate_micro" ], "properties": { "gpu_model": { "type": "string" }, "sample_size": { "type": "integer", "description": "Listed machines of this model; the denominator of every metric below." }, "listed_gpus": { "anyOf": [ { "type": "integer" }, { "type": "null" } ] }, "allocated_gpus": { "anyOf": [ { "type": "integer" }, { "type": "null" } ] }, "utilization_pct": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Floored allocated/listed GPU percent." }, "rate_micro": { "anyOf": [ { "type": "object", "additionalProperties": false, "required": [ "p10_micro", "median_micro", "p90_micro" ], "properties": { "p10_micro": { "$ref": "#/components/schemas/MicroAmount" }, "median_micro": { "$ref": "#/components/schemas/MicroAmount" }, "p90_micro": { "$ref": "#/components/schemas/MicroAmount" } } }, { "type": "null" } ] }, "fill_rate_pct": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "Floored share of listed machines rented at least once in the window." }, "rental_sample_size": { "anyOf": [ { "type": "integer" }, { "type": "null" } ] }, "median_time_to_first_rental_s": { "anyOf": [ { "$ref": "#/components/schemas/DecimalString" }, { "type": "null" } ] }, "your_rate_micro": { "anyOf": [ { "$ref": "#/components/schemas/MicroAmount" }, { "type": "null" } ], "description": "The caller's own median listed rate for this model." } } } } }}default
Section titled “default”Error envelope. 401 unauthenticated, 403/404 forbidden, 409 conflict, 422 invalid input, 429 rate limited (code UNAVAILABLE, retryable:true, no Retry-After header), 503 unavailable money/provider state with retryable:true.
application/json
| Field | Type | Presence | Description |
|---|---|---|---|
error | object | Required |
{ "$ref": "#/components/schemas/ErrorEnvelope"}Static request outline
Section titled “Static request outline”Replace path/query placeholders and provide the required JSON body, headers and credential from the sections above. This is a request outline, not a command that chooses an amount or starts a rental for you.
curl --request GET 'https://amplerun-api.spiry.org/api/v1/hosts/market' \ --header "Authorization: Bearer $AMPLERUN_API_KEY"Schema definitions · Download OpenAPI · Authentication · Errors and recovery
Official AmpleRun documentation · Contract v3 · Generated from the API contract · Revision 52fe29de · Open AmpleRun · View Markdown · For agents