Per-gram gold price by karat purity
Changed onPer-gram XAU price for karats 24 / 22 / 21 / 20 / 18 / 16 / 14 / 10.
Logic: per_gram_24k = spot_xau_usd_per_oz / GRAMS_PER_TROY_OUNCE * fx_rate; per_gram_Nk = per_gram_24k * N/24.
Historical date support is not implemented; omit the param or use /v1/prices/history + do the math client-side.
Request
- Base URLhttps://api.goldprice.dev
- URLhttps://api.goldprice.dev/v1/carat
- Auth
- none
- or HTTP bearer
- or API key in header X-API-Key
Query parameters
Quote currency (default USD).
Response
Successful Response
Changes
- breaking
the response property
became optional for the status - breaking
the response property
became optional for the status - breaking
the response property
became optional for the status - breaking
the response property
became optional for the status - breaking
response property
messagelist-of-types was widened by adding typesnullto media typeapplication/jsonof response400 - breaking
response property
messagelist-of-types was widened by adding typesnullto media typeapplication/jsonof response401 - breaking
response property
messagelist-of-types was widened by adding typesnullto media typeapplication/jsonof response429 - breaking
response property
messagelist-of-types was widened by adding typesnullto media typeapplication/jsonof response503 - warning
removed the optional property
from the response with the status - info
the endpoint scheme security
ApiKeyAuthwas added to the API - info
the endpoint scheme security
BearerAuthwas added to the API - info
added the non-success response with the status
- info
removed the non-success response with the status
- info
removed the non-success response with the status
- info
added the required property
to the response with the status - info
added the required property
to the response with the status - info
added the required property
to the response with the status
- breaking