Skip to Content
Grail Network
API reference

Set the price adjustment of a card

Sets the price of the card in relation to its market price: from "-0.10" (10% below) to "0.10" (10% above), with at most four decimals. A card goes on sale in packs when it has a price adjustment and a market price. The same value again changes nothing. No money moves. Errors: - 400 `VALIDATION_FAILED` at `priceAdjustment`: not a decimal with at most four decimals, or outside the range. - 404 `PARTNER_ITEM_NOT_FOUND`: you have no card with this id. - 409 `PARTNER_ITEM_TAKEN_BACK`: the card has a take-back request, so its price stays as it is. - 409 `PARTNER_ITEM_SOLD`: the card is sold. - 503 `SERVICE_UNAVAILABLE` with the header `Retry-After: 5`: a system that this request needs gave no answer. Send the same request again after 5 seconds.

PATCH
/partner/items/{itemId}

Sets the price of the card in relation to its market price: from "-0.10" (10% below) to "0.10" (10% above), with at most four decimals. A card goes on sale in packs when it has a price adjustment and a market price. The same value again changes nothing. No money moves.

Errors:

  • 400 VALIDATION_FAILED at priceAdjustment: not a decimal with at most four decimals, or outside the range.
  • 404 PARTNER_ITEM_NOT_FOUND: you have no card with this id.
  • 409 PARTNER_ITEM_TAKEN_BACK: the card has a take-back request, so its price stays as it is.
  • 409 PARTNER_ITEM_SOLD: the card is sold.
  • 503 SERVICE_UNAVAILABLE with the header Retry-After: 5: a system that this request needs gave no answer. Send the same request again after 5 seconds.

Authorization

partnerApiKey
headerAuthorizationBearer <token>

The partner's API key.

Path Parameters

itemId*string

The card's id at Grail Network

Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid

Request Body

application/json
  1. body
priceAdjustment*string

A decimal text from "-0.10" to "0.10", with at most four decimals: "0.05" sets the price 5% above the market price, "-0.025" 2.5% below it

Match^-?(?:0|[1-9]\d*)(?:\.\d{1,4})?$

Response Body

application/json
  1. response
data*
Example Request
curl -X PATCH 'https://api-stg.grailnetwork.com/partner/items/497f6eca-6276-4993-bfeb-53cbbbba6f08' \  -H 'Content-Type: application/json' \  -d '{  "priceAdjustment": "string"}'
Example Response
{  "data": {    "itemId": "f11b669d-7201-4c21-88af-d85092f0c005",    "reference": "string",    "receivedAt": "2019-08-24T14:15:22Z",    "card": {      "name": "string",      "setName": "string",      "categoryName": "string",      "number": "string",      "gradeName": "string"    },    "frontPictureUrl": "string",    "state": "available",    "marketPrice": {      "amountAtomic": "string",      "currency": "string"    },    "priceAdjustment": "string",    "price": {      "amountAtomic": "string",      "currency": "string"    },    "pulledAt": "2019-08-24T14:15:22Z",    "priceAtPull": {      "amountAtomic": "string",      "currency": "string"    },    "buybackOfferEndsAt": "2019-08-24T14:15:22Z",    "soldAt": "2019-08-24T14:15:22Z",    "takeBack": {      "state": "requested",      "requestedAt": "2019-08-24T14:15:22Z",      "noticeEndsAt": "2019-08-24T14:15:22Z",      "completedAt": "2019-08-24T14:15:22Z"    },    "changedAt": "2019-08-24T14:15:22Z"  }}

Read your partner record GET

Your id, name and code at Grail Network, your webhook address, the notice of a take-back request today, and the range of the price adjustment that you may set on a card.

Set your webhook address PUT

Sets the address that gets your webhooks. The first address makes a secret, and this answer shows it once: keep it, because no later answer shows it. A new address keeps the secret. `null` removes the address and the secret, and the webhooks that wait end with no delivery. Grail Network checks the address again before each try. **What arrives at the address.** Grail Network posts one JSON body for each fact, signed by the rules of the Standard Webhooks specification (standardwebhooks.com). A webhook is thin: it names the fact, and you read the API for the facts themselves. The body: `{ "id": "<uuid>", "type": "<type>", "createdAt": "2026-11-24T10:00:00.000Z", "data": { … } }`. `id` is the same at each try of one webhook: keep it, and handle an `id` once. The types and their `data`: - `partner-item.changed`: `{ "itemId": "<uuid>", "reference": "7K3M9QX2G" }`. One of your cards changed: a buyer got it, its price, its sale, a take-back request or its completion. Read `GET /partner/items/{itemId}`. - `intake.ended`: `{ "intakeId": "<uuid>", "reference": "7K3M9QX2G" }`. The warehouse ended the intake of one of your slips. Read `GET /partner/intakes?reference=` and `GET /partner/items?reference=`. - `pool.created`: `{ "poolDay": "2026-11-23" }`. The pool of that UTC day gave you at least one share. Read `GET /partner/report-lines` from your last cursor. **The check of the signature.** The headers: `webhook-id` (the body's `id`), `webhook-timestamp` (Unix seconds), and `webhook-signature`: `v1,<signature>`, where the signature is the base64 of HMAC-SHA256 over the text `<webhook-id>.<webhook-timestamp>.<the raw body>`. The key of the HMAC is the bytes of the base64 after `whsec_` in your secret. Compare the signatures in constant time, and refuse a timestamp more than 5 minutes from your clock. After a new secret, the next try of every webhook is signed with the new one. **Your answer and the tries.** Answer 2xx within 10 seconds, after the check of the signature, also for a fact that you cannot place yet: keep it in a place of your own and read the API. Any other answer, or no answer, is a failed try. Grail Network tries 8 times, with these waits after a failed try: 1 minute, 5 minutes, 30 minutes, 2 hours, 5 hours, 10 hours, 10 hours. So the last try is about 27.6 hours after the first, and then the webhook has failed for good. No route sends a webhook again: a webhook is a nudge, and `GET /partner/items?changedAfter=` and `GET /partner/report-lines?after=` from your last cursors give you everything that you missed. Errors: - 400 `VALIDATION_FAILED` at `url`: the address is not `https://`, or it has more than 2,000 characters. - 409 `PARTNER_WEBHOOK_URL_INVALID`: the host of the address is a private address, or it is not found.