API reference
Shop Pulls_create
POST
shopApiKeyheader
AuthorizationBearer <token>The shop's API key.
application/json- body
requestId*stringThe shop's own id of the request: the same id with the same body answers the same pull
Length
1 <= length <= 200packId*stringMatch
^([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)$Format
uuidbuyerId*stringThe shop's own id of the buyer
Length
1 <= length <= 200packCount*integerThe number of packs to open: 1 to 5
Range
1 <= value <= 5packPrice*The pack price that the buyer saw
commitmentId*stringThe commitment of POST /shop/pull-commitments
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)$Format
uuidclientSeed*stringThe shop's seed: 1 to 128 printable ASCII characters, with no space and no ":"
Match
^[!-9;-~]{1,128}$application/json- response
data*curl -X POST 'https://api-stg.grailnetwork.com/shop/pulls' \ -H 'Content-Type: application/json' \ -d '{ "requestId": "string", "packId": "76be6288-f84b-4cef-9c7f-e3c35001eada", "buyerId": "string", "packCount": 1, "packPrice": { "amountAtomic": "string", "currency": "USD" }, "commitmentId": "4e1ecf7c-8127-4207-92b0-010ff43ff54d", "clientSeed": "string"}'Example Response
{ "data": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "requestId": "string", "packId": "76be6288-f84b-4cef-9c7f-e3c35001eada", "packVersion": -9007199254740991, "buyerId": "string", "packCount": -9007199254740991, "packPrice": { "amountAtomic": "string", "currency": "USD" }, "amount": { "amountAtomic": "string", "currency": "USD" }, "state": "started", "reason": "balance_too_low", "createdAt": "2019-08-24T14:15:22Z", "buybackOfferEndsAt": "2019-08-24T14:15:22Z", "serverSeedHash": "string", "serverSeed": "string", "clientSeed": "string", "packs": [ { "index": -9007199254740991, "cards": [ { "slotPosition": -9007199254740991, "tierName": "string", "holdingId": "51ebd04a-ea04-425f-9017-f69b7702e7a3", "priceAtHold": { "amountAtomic": "string", "currency": "USD" }, "payout": { "amountAtomic": "string", "currency": "USD" }, "item": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "cardName": "string", "cardNumber": "string", "setName": "string", "categoryName": "string", "gradeName": "string", "conditionName": "string", "frontPictureUrl": "string" } } ], "featuredRoll": "hit", "featuredCard": { "holdingId": "51ebd04a-ea04-425f-9017-f69b7702e7a3", "priceAtHold": { "amountAtomic": "string", "currency": "USD" }, "payout": { "amountAtomic": "string", "currency": "USD" }, "item": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "cardName": "string", "cardNumber": "string", "setName": "string", "categoryName": "string", "gradeName": "string", "conditionName": "string", "frontPictureUrl": "string" } } } ] }}