{"openapi":"3.1.0","info":{"title":"De todo un poco API","version":"1.0.0","description":"Everything a person can do in this shop, a program can do: look at the catalogue, prepare a cart and, when the person says yes, place the order.\nAn assistant that buys here never pays and never sees payment details: placing the order only creates it. The person authorises it with a 6-digit code the shop emails them, and pays afterwards, themselves, on the page of the shop. So when a person asks you to buy something here for them, you can: you do not need their card, their PayPal or a key. If you would rather not send their details, prepare the cart and give them the checkout-link address: never just tell them you cannot.\n\nHow to buy, step by step:\n1. Find the product: GET /search?q=… or GET /products, then GET /products/{id} for its variants and GET /products/{id}/availability.\n2. POST /carts gives you a cart token. From now on send it as X-Cart-Token.\n3. POST /carts/current/items adds products ({\"product_id\":12,\"variant_id\":0,\"qty\":1}). The price is always the shop's own.\n4. POST /carts/checkout/customer saves the person's contact and address (their own words in \"text\", or separate fields).\n5. POST /carts/checkout/shipping-options, then POST /carts/checkout/shipping {\"carrier_id\":…}.\n6. POST /carts/checkout/payment-options, then POST /carts/checkout/payment {\"method\":\"…\"}.\n7. POST /carts/checkout/review returns the exact order, its total (in cents and formatted) and a confirm_token. Show the person that total and the terms (terms_url) and wait for a clear yes. For security the shop emails a 6-digit verification code to the buyer at this step (see \"confirmation\" in the answer): tell the person, ask for the code and wait for it.\n8. POST /carts/checkout/place {\"confirm_token\":\"…\",\"buyer_confirmed\":true} places the order. Add \"buyer_code\":\"…\", the code the buyer received by email; a key with the scope orders:create (Authorization: Bearer …) does not need it. buyer_confirmed is your declaration that the person has seen the total and said yes: without it nothing is placed.\n9. The answer has the order number, the order page and \"payment\": either \"instructions\" (bank transfer, cash on delivery) or \"redirect\", the address where the person pays. No gateway is paid without the person.\n\nIf you can only open addresses (GET) and cannot send a POST or a header, buy with links: GET /go explains it and GET /go/start gives you a cart; every answer has the next addresses ready in \"next\".\nIf the person prefers to pay on the web, GET /carts/current/checkout-link gives an address that opens this cart in their browser and takes them to the checkout.\nIf anything changes after the review (a quantity, the address, the shipping, the payment, a coupon or the total), the confirm_token stops being valid and nothing is placed: review again.\nThe shop sets a highest amount per order and a number of orders per key (or per address) and hour. Above them, or if the shop does not take orders from programs, send the person to the checkout page."},"servers":[{"url":"https://detodounpoco.gmartos.es/api/v1"}],"tags":[{"name":"Catalogue","description":"Read the shop without a key. Prices are always in cents and, next to them, formatted."},{"name":"Cart","description":"Prepare a cart. The token of POST /carts travels in the X-Cart-Token header."},{"name":"Checkout","description":"Take the purchase to the end. The person always confirms the total."}],"paths":{"/store":{"get":{"operationId":"api.store","summary":"The shop: name, currency, languages, contact, returns, payment methods and where to find everything else","tags":["Catalogue"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"store_info"}},"/categories":{"get":{"operationId":"api.categories","summary":"The product categories with their sub-categories","tags":["Catalogue"],"responses":{"200":{"description":"Success: a list in \"data\" and its page in \"meta\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAnswer"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"list_categories"}},"/products":{"get":{"operationId":"api.products.list","summary":"List the products, with search, category, stock filter, order and pages","tags":["Catalogue"],"responses":{"200":{"description":"Success: a list in \"data\" and its page in \"meta\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAnswer"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"parameters":[{"name":"q","in":"query","required":false,"description":"Words to look for","schema":{"type":"string"}},{"name":"category","in":"query","required":false,"description":"Only products of this category id","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number, from 1","schema":{"type":"integer"}},{"name":"per_page","in":"query","required":false,"description":"Products per page, 1 to 48 (24 by default)","schema":{"type":"integer"}},{"name":"sort","in":"query","required":false,"description":"relevance, newest, price_asc, price_desc, name or best","schema":{"type":"string"}},{"name":"in_stock","in":"query","required":false,"description":"true: only products in stock","schema":{"type":"boolean"}}]}},"/products/{id}":{"get":{"operationId":"api.products.show","summary":"Everything the shop says about one product","tags":["Catalogue"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"What the address names does not exist (a product, a cart line…)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"get_product","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}]}},"/products/{id}/availability":{"get":{"operationId":"api.products.availability","summary":"Whether a product or variant can be bought in a quantity right now","tags":["Catalogue"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"What the address names does not exist (a product, a cart line…)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"check_availability","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"name":"variant_id","in":"query","required":false,"description":"The variant, for a product with variants","schema":{"type":"integer"}},{"name":"qty","in":"query","required":false,"description":"Units, 1 to 999 (1 by default)","schema":{"type":"integer"}}]}},"/search":{"get":{"operationId":"api.search","summary":"Search the catalogue: up to 8 products with the facts that match","tags":["Catalogue"],"responses":{"200":{"description":"Success: a list in \"data\" and its page in \"meta\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAnswer"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"search_products","parameters":[{"name":"q","in":"query","required":true,"description":"What the customer is looking for, in their own words (required)","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Products, 1 to 8 (5 by default)","schema":{"type":"integer"}},{"name":"category","in":"query","required":false,"description":"Only products of this category id","schema":{"type":"string"}},{"name":"max_price_cents","in":"query","required":false,"description":"Highest price in cents","schema":{"type":"integer"}},{"name":"in_stock","in":"query","required":false,"description":"true: only products in stock","schema":{"type":"boolean"}}]}},"/shipping/quote":{"get":{"operationId":"api.shipping.quote","summary":"Delivery options, prices and times for a product to a destination","tags":["Catalogue"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"shipping_quote","parameters":[{"name":"country","in":"query","required":false,"description":"ISO 3166-1 alpha-2 code","schema":{"type":"string"}},{"name":"postcode","in":"query","required":false,"description":"Postcode of the destination","schema":{"type":"string"}},{"name":"product_id","in":"query","required":true,"description":"The product to quote (required)","schema":{"type":"integer"}},{"name":"variant_id","in":"query","required":false,"description":"The variant","schema":{"type":"integer"}},{"name":"qty","in":"query","required":false,"description":"Units, 1 to 999 (1 by default)","schema":{"type":"integer"}}]}},"/carts":{"post":{"operationId":"api.carts.create","summary":"Create an empty cart and get its token (the token travels afterwards in the X-Cart-Token header)","tags":["Cart"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"cart_view"}},"/carts/current":{"get":{"operationId":"api.carts.show","summary":"The cart with its lines and totals as the shop calculates them","tags":["Cart"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"cart_view","security":[{"cartToken":[]}]}},"/carts/current/items":{"post":{"operationId":"api.carts.items.add","summary":"Add units of a product to the cart (the price is always the shop's own)","tags":["Cart"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"cart_add","security":[{"cartToken":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"product_id":{"type":"integer","description":"The product (required)"},"variant_id":{"type":"integer","description":"The variant, for a product with variants"},"qty":{"type":"integer","description":"Units, 1 to 99 (1 by default)"}},"required":["product_id"]}}}}}},"/carts/current/items/{key}":{"patch":{"operationId":"api.carts.items.update","summary":"Change the quantity of a cart line (0 removes it)","tags":["Cart"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"What the address names does not exist (a product, a cart line…)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"cart_update","security":[{"cartToken":[]}],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"qty":{"type":"integer","description":"The new quantity, 0 to 99 (required)"}},"required":["qty"]}}}}},"delete":{"operationId":"api.carts.items.remove","summary":"Remove a line from the cart","tags":["Cart"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"What the address names does not exist (a product, a cart line…)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"cart_update","security":[{"cartToken":[]}],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string"}}]}},"/carts/current/checkout-link":{"get":{"operationId":"api.carts.checkout_link","summary":"The address that opens this cart in the customer's browser and takes them to the checkout","tags":["Cart"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_link","security":[{"cartToken":[]}]}},"/carts/checkout/status":{"post":{"operationId":"api.checkout.status","summary":"Where the purchase is: what is missing, the cart and what is saved (personal data come masked)","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_status","security":[{"cartToken":[]}]}},"/carts/checkout/customer":{"post":{"operationId":"api.checkout.customer","summary":"Save the customer's contact and address: their own words in text, or separate fields","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_set_customer","security":[{"cartToken":[]}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","description":"What the customer wrote about themselves, in any order"},"email":{"type":"string","description":"Email"},"first_name":{"type":"string","description":"First name"},"last_name":{"type":"string","description":"Last name"},"company":{"type":"string","description":"Company"},"vat_id":{"type":"string","description":"Tax ID"},"phone":{"type":"string","description":"Phone"},"line1":{"type":"string","description":"Street and number"},"line2":{"type":"string","description":"Floor, door"},"postcode":{"type":"string","description":"Postcode"},"city":{"type":"string","description":"City"},"region":{"type":"string","description":"Region code"},"country":{"type":"string","description":"ISO 3166-1 alpha-2 code"},"address_id":{"type":"integer","description":"A saved address of a customer with an account"},"note":{"type":"string","description":"A note for the order"}}}}}}}},"/carts/checkout/shipping-options":{"post":{"operationId":"api.checkout.shipping_options","summary":"The delivery options of the order with price and delay","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_shipping_options","security":[{"cartToken":[]}]}},"/carts/checkout/shipping":{"post":{"operationId":"api.checkout.shipping","summary":"Choose the delivery option","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_set_shipping","security":[{"cartToken":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"carrier_id":{"type":"integer","description":"The id from the shipping options (required)"}},"required":["carrier_id"]}}}}}},"/carts/checkout/payment-options":{"post":{"operationId":"api.checkout.payment_options","summary":"The payment methods offered for the order","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_payment_options","security":[{"cartToken":[]}]}},"/carts/checkout/payment":{"post":{"operationId":"api.checkout.payment","summary":"Choose the payment method","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_set_payment","security":[{"cartToken":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"method":{"type":"string","description":"The id from the payment options (required)"}},"required":["method"]}}}}}},"/carts/checkout/review":{"post":{"operationId":"api.checkout.review","summary":"The exact order that would be placed, with its total and the confirm_token to place it","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_review","security":[{"cartToken":[]}]}},"/carts/checkout/place":{"post":{"operationId":"api.checkout.place","summary":"Place the order. Needs the confirm_token of the review, buyer_confirmed true and the code emailed to the buyer (buyer_code) or a key with the orders:create scope","tags":["Checkout"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"403":{"description":"The buyer code is wrong or too old, or the shop does not take orders from programs","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"The cart token is missing or wrong","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-tool":"checkout_place","security":[{"cartToken":[]},{"cartToken":[],"bearerAuth":[]}],"x-optional-scope":"orders:create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"confirm_token":{"type":"string","description":"The confirm_token of the last review (required)"},"buyer_confirmed":{"type":"boolean","description":"true: the person has seen the total and said yes (required)"},"buyer_code":{"type":"string","description":"The 6-digit code the shop emailed to the buyer after the review. Not needed with a key that has the orders:create scope"}},"required":["confirm_token","buyer_confirmed"]}}}}}},"/go":{"get":{"operationId":"api.go.guide","summary":"Buying with links: how an assistant that can only open addresses buys here, and where it starts","tags":["Buying with links (GET only)"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/go/{step}":{"get":{"operationId":"api.go.step","summary":"One step of buying with links: start, add, cart, customer, shipping-options, shipping, payment-options, payment, status, review, code or place. Every answer has the next addresses ready","tags":["Buying with links (GET only)"],"responses":{"200":{"description":"Success: the answer in \"data\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Answer"}}}},"400":{"description":"A parameter or a field of the body is missing or not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"What the address names does not exist (a product, a cart line…)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many requests: wait the seconds of Retry-After","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"parameters":[{"name":"step","in":"path","required":true,"schema":{"type":"string"}},{"name":"cart","in":"query","required":false,"description":"The cart, as the step start gives it (every step but start)","schema":{"type":"string"}},{"name":"product_id","in":"query","required":false,"description":"add: the product","schema":{"type":"integer"}},{"name":"variant_id","in":"query","required":false,"description":"add: the variant, for a product with variants","schema":{"type":"integer"}},{"name":"qty","in":"query","required":false,"description":"add: units","schema":{"type":"integer"}},{"name":"text","in":"query","required":false,"description":"customer: what the person wrote about themselves, in any order","schema":{"type":"string"}},{"name":"carrier_id","in":"query","required":false,"description":"shipping: the id from shipping-options","schema":{"type":"integer"}},{"name":"method","in":"query","required":false,"description":"payment: the id from payment-options","schema":{"type":"string"}},{"name":"confirm_token","in":"query","required":false,"description":"place: the confirm_token of the review","schema":{"type":"string"}},{"name":"buyer_confirmed","in":"query","required":false,"description":"place: true, the person has seen the total and said yes","schema":{"type":"string"}},{"name":"buyer_code","in":"query","required":false,"description":"place: the 6-digit code the shop sent to the buyer","schema":{"type":"string"}},{"name":"digits","in":"query","required":false,"description":"code: the digits of that code entered so far, for tools that only open addresses written in a page","schema":{"type":"string"}}]}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"A key made in the shop panel. It raises the usage limit; the scope orders:create lets it place orders without the code emailed to the buyer."},"cartToken":{"type":"apiKey","in":"header","name":"X-Cart-Token","description":"The token that POST /carts gave you."}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["status","message"],"properties":{"status":{"type":"integer","description":"The HTTP status"},"message":{"type":"string","description":"What went wrong, in plain words"}}}}},"Answer":{"type":"object","required":["data"],"properties":{"data":{"type":"object","description":"What was asked for. Prices come in cents (price, total_cents…) and, next to them, formatted for people (price_formatted, total_formatted…). Never calculate them yourself.","additionalProperties":true}}},"ListAnswer":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true},"description":"The items of this page"},"meta":{"type":"object","description":"The page: page, per_page and total","properties":{"page":{"type":"integer"},"per_page":{"type":"integer"},"total":{"type":"integer"}},"additionalProperties":true}}}}}}