Estimate Job Cost
Changed onEstimate 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
Request
- Base URLhttps://api-v2.qbraid.com/api/v1
- URLhttps://api-v2.qbraid.com/api/v1/jobs/cost-estimate
- AuthAPI key in header X-API-KEY
Query parameters
Device QRN (qBraid Resource Name)
Device to quote
Shot count to quote for
Shot count to quote for. Defaults to 1000.
Response
Successful Response
Changes
- info
endpoint added
- info