---
title: "Estimate Job Cost"
method: GET
path: "/jobs/cost-estimate"
tags: ["jobs"]
---

# Estimate Job Cost

`GET /jobs/cost-estimate`

## Request

- Base URL: `https://api-v2.qbraid.com/api/v1`
- URL: `https://api-v2.qbraid.com/api/v1/jobs/cost-estimate`
- Auth: API key in header `X-API-KEY`

Estimate the cost, in qBraid credits, of running a job on a device before submitting it.

The quote is a guide, not a cap. When you submit a job, its estimated cost is held from your credit balance; when the job finishes, you are charged its actual cost and the difference is refunded or debited. A job that runs longer than quoted is billed for what it used. A QPU is quoted from that device's execution history. A simulator is quoted from a fixed conservative duration, so its quote does not change with the shot count.

A device whose pricing cannot be quoted is a state, not an error: the response has `pricingAvailable: false` and a `reason`.

**Args:**
- **deviceQrn** (string): Device QRN (qBraid Resource Name)
- **shots** (integer, optional): Shot count to quote for. Defaults to 1000.

**Returns:**
- A quote with `estimatedCost` when `pricingAvailable` is true, or a `reason` when it is false

**Raises:**
- **400**: `deviceQrn` is missing or `shots` is outside 1 to 100000
- **403**: You do not have device execution permission for this device
- **404**: Device is not found
- **410**: Device is retired

## Query parameters

- `deviceQrn` string, required: Device QRN (qBraid Resource Name)
- `shots` integer: Shot count to quote for

## Response `200`

Successful Response

- CostEstimateResponse: Response schema for a job cost estimate
  - `success` boolean, required
  - `data` union, required
    - CostEstimateAvailable: A quote for a device with usable pricing
      - `pricingAvailable` true, required: Always true for this shape
      - `estimatedCost` number, required: Estimated cost in qBraid credits
      - `deviceQrn` string, required: Device the quote is for
      - `shots` integer: Shot count the quote assumes. Only present when `shots` was passed in the request.
    - CostEstimateUnavailable: The device's pricing cannot be quoted
      - `pricingAvailable` false, required: Always false for this shape
      - `reason` 'no_pricing_configured' | 'dynamic_pricing_unavailable', required: Why no cost could be quoted. `no_pricing_configured`: the device has no price data. `dynamic_pricing_unavailable`: the price depends on the submitted program and cannot be quoted up front.
      - `deviceQrn` string, required: Device the quote is for
      - `pricingModel` 'fixed' | 'dynamic', nullable, required: The device's pricing model, or null if none is configured

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `404`: Device Not Found
- `410`: Device Retired

## Changes

- **2026-11-03** `20848d926124`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/qbraid/apis/qbraid-runtime-api/changes/jobs/cost-estimate/get.md)

---

[API](https://skmtc.dev/qbraid/apis/qbraid-runtime-api.md) - [All operations](https://skmtc.dev/qbraid/apis/qbraid-runtime-api/llms.txt) - [OpenAPI document](https://skmtc.dev/qbraid/apis/qbraid-runtime-api/revisions/20848d926124?raw)
