Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in inputRequests on Cart Purchase Status, each with an expiresAt. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with lastAnswerRejected: true.
POST
/
cart
/
purchase
/
input
JavaScript
import HenrySDK from '@henrylabs/sdk';const client = new HenrySDK({ apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted});const response = await client.cart.checkout.submitPurchaseInput({ requestId: 'inp-ref_3fa85f64-5717-4562-b3fc', value: '482913',});console.log(response.details);
The buyer's answer, by the request's type. code: the code as a string; spaces and dashes are dropped, and it is otherwise 4 to 10 letters and digits. text: one line of text. choice: the id of the option picked. confirm: true or false. An approval or a link request takes no answer.
Maximum string length: 200
Example:
"482913"
Response
The answer was accepted and the purchase goes on with it. The order, still processing
pending / processing while the purchase runs. It then settles: complete (every item bought), partially_complete (some items bought — see products[].status), failed (nothing bought — see error), or cancelled (stopped by Cart Purchase Cancel before anything was bought). An order can stay processing for up to an hour before it settles.
Available options:
pending,
processing,
complete,
partially_complete,
failed,
cancelled
products
object[]
required
Show child attributes
details
object
required
Show child attributes
inputRequests
object[]
required
What the purchase is waiting on the buyer for, while it is processing: most often a code a store sent them. Show each request's message to the buyer and answer it with Cart Purchase Input before its expiresAt. Empty when the purchase is waiting on nothing, which is nearly always, and always when the purchase was made with allowInputRequests: false.
Option 1
Option 2
Option 3
Option 4
Option 5
Option 6
Show child attributes
result
object
Show child attributes
error
object
Why items failed, once the order has settled as failed or partially_complete. Absent while the purchase runs and when every item was bought.
Show child attributes
Was this page helpful?
⌘I
JavaScript
import HenrySDK from '@henrylabs/sdk';const client = new HenrySDK({ apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted});const response = await client.cart.checkout.submitPurchaseInput({ requestId: 'inp-ref_3fa85f64-5717-4562-b3fc', value: '482913',});console.log(response.details);
{"docsConfig":{"theme":"almond","$schema":"https://mintlify.com/docs.json","name":"Henry Docs","description":"Henry Labs is a commerce API for apps and AI agents. Search products, build multi-merchant carts, and check out at online merchants with one SDK and one API key.","colors":{"primary":"#F95D24","light":"#F95D24","dark":"#F95D24"},"logo":{"light":"https://mintcdn.com/henrysocial/Hwbu9SUy5nEnx_Uc/images/logo-light.svg?fit=max\u0026auto=format\u0026n=Hwbu9SUy5nEnx_Uc\u0026q=85\u0026s=3b5de7db65089f45a1db621b6ffa9a88","dark":"https://mintcdn.com/henrysocial/Hwbu9SUy5nEnx_Uc/images/logo-dark.svg?fit=max\u0026auto=format\u0026n=Hwbu9SUy5nEnx_Uc\u0026q=85\u0026s=54397c2fc3e7793d5b6bd7101e594975"},"favicon":"https://mintcdn.com/henrysocial/Hwbu9SUy5nEnx_Uc/images/icon.svg?fit=max\u0026auto=format\u0026n=Hwbu9SUy5nEnx_Uc\u0026q=85\u0026s=9f49f9f57f59d7b2ac56b065ac3fe7ee","api":{"playground":{"display":"simple"}},"appearance":{"default":"dark"},"navbar":{"links":[{"href":"mailto:support@henrylabs.ai","label":"Talk to us"}],"primary":{"type":"button","label":"Dashboard ➔","href":"https://app.henrylabs.ai"}},"footer":{},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"henrysocial","hasAudioNarration":false,"actualSubdomain":"henrysocial","customDomains":["docs.henrylabs.ai"],"gitSource":{"type":"github","owner":"henry-social","repo":"henry","deployBranch":"main","contentDirectory":"apps/public-docs","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6b0a0372f866cf6449e79892","clientVersion":"0.0.4342","searchFilterCounts":[{"language":"default","tag":"API Reference","count":31},{"language":"default","tag":"Server SDK","count":27},{"language":"default","tag":"Agents","count":14},{"language":"default","tag":"Cart","count":13},{"language":"default","tag":"Client SDK","count":12},{"language":"default","tag":"AI Agents","count":12},{"language":"default","tag":"Key Features","count":7},{"language":"default","tag":"Info","count":6},{"language":"default","tag":"Getting Started","count":6},{"language":"default","tag":"Card","count":6}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"site-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"treatment","enabled":true,"payload":{"type":"string","value":"treatment"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":true},"customCss":[]}
{"page":{"pagePath":"api-reference/cart/cart-purchase-input","slug":"/api-reference/cart/cart-purchase-input","pageMetadata":{"title":"Cart Purchase Input","description":"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in `inputRequests` on Cart Purchase Status, each with an `expiresAt`. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with `lastAnswerRejected: true`.","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/purchase/input","href":"/api-reference/cart/cart-purchase-input","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n code: \"code\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_components.p, {\n children: [\"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in \", _jsx(_components.code, {\n children: \"inputRequests\"\n }), \" on Cart Purchase Status, each with an \", _jsx(_components.code, {\n children: \"expiresAt\"\n }), \". The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with \", _jsx(_components.code, {\n children: \"lastAnswerRejected: true\"\n }), \".\"]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Cart Purchase Input","description":"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in `inputRequests` on Cart Purchase Status, each with an `expiresAt`. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with `lastAnswerRejected: true`.","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/purchase/input","href":"/api-reference/cart/cart-purchase-input","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"operationId":"cartPurchaseInput","summary":"Cart Purchase Input","description":"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in `inputRequests` on Cart Purchase Status, each with an `expiresAt`. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with `lastAnswerRejected: true`.","tags":["Cart"],"security":["2e218555-ce8e-430f-8265-c31f1226f7ef"],"requestBody":"e1cecc3b-86f6-4336-834a-20fd3a5c7003","responses":{"200":"ff014c92-6be8-486e-a4a1-0af7f4a1ebb1","400":"95632215-6933-4420-87c2-1662695c679d","401":"2154f128-fff9-4a6e-a4c4-09c97cf83300","404":"81205669-9c8a-4cf2-8ee8-ffac84496d0c","409":"88532171-82bf-4c22-94f9-7abb57648514"},"x-codeSamples":[{"lang":"JavaScript","source":"import HenrySDK from '@henrylabs/sdk';\n\nconst client = new HenrySDK({\n apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted\n});\n\nconst response = await client.cart.checkout.submitPurchaseInput({\n requestId: 'inp-ref_3fa85f64-5717-4562-b3fc',\n value: '482913',\n});\n\nconsole.log(response.details);"}],"method":"post","type":"path","servers":["54422345-6881-415a-94f8-63946d7dcab9"],"path":"/cart/purchase/input","baseUrlOptions":["https://api.henrylabs.ai/v1"],"title":"Cart Purchase Input","codeSamples":[{"lang":"JavaScript","source":"import HenrySDK from '@henrylabs/sdk';\n\nconst client = new HenrySDK({\n apiKey: process.env['HENRY_SDK_API_KEY'], // This is the default and can be omitted\n});\n\nconst response = await client.cart.checkout.submitPurchaseInput({\n requestId: 'inp-ref_3fa85f64-5717-4562-b3fc',\n value: '482913',\n});\n\nconsole.log(response.details);"}],"requiredOnlyExamples":false,"requestExampleType":"codeSamples","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"content":{"application/json":{"example":{"requestId":"inp-ref_3fa85f64-5717-4562-b3fc","value":"482913"},"schema":{"type":"object","properties":{"requestId":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The id of the input request being answered, from `inputRequests[].id` on Cart Purchase Status","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"requestId","typeLabel":"string"},"value":{"oneOf":[{"type":"string","description":"The buyer's answer, by the request's `type`. `code`: the code as a string; spaces and dashes are dropped, and it is otherwise 4 to 10 letters and digits. `text`: one line of text. `choice`: the `id` of the option picked. `confirm`: `true` or `false`. An `approval` or a `link` request takes no answer.","maxLength":200,"example":"482913","isRequired":true,"uniqueKey":"value.oneOf.0","typeLabel":"string"},{"type":"boolean","description":"The buyer's answer, by the request's `type`. `code`: the code as a string; spaces and dashes are dropped, and it is otherwise 4 to 10 letters and digits. `text`: one line of text. `choice`: the `id` of the option picked. `confirm`: `true` or `false`. An `approval` or a `link` request takes no answer.","example":"482913","isRequired":true,"uniqueKey":"value.oneOf.1","typeLabel":"boolean"}],"isRequired":true,"uniqueKey":"value","typeLabel":"string | boolean"}},"required":["requestId","value"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"requestId":"inp-ref_3fa85f64-5717-4562-b3fc","value":"482913"}}},"exampleType":"examples"}},"exampleType":"examples"},"responses":{"ff014c92-6be8-486e-a4a1-0af7f4a1ebb1":{"description":"The answer was accepted and the purchase goes on with it. The order, still `processing`","content":{"application/json":{"schema":{"type":"object","properties":{"refId":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","isRequired":true,"uniqueKey":"refId","typeLabel":"string"},"status":{"type":"string","enum":["pending","processing","complete","partially_complete","failed","cancelled"],"description":"`pending` / `processing` while the purchase runs. It then settles: `complete` (every item bought), `partially_complete` (some items bought — see `products[].status`), `failed` (nothing bought — see `error`), or `cancelled` (stopped by Cart Purchase Cancel before anything was bought). An order can stay `processing` for up to an hour before it settles.","isRequired":true,"uniqueKey":"status","typeLabel":"enum\u003cstring>"},"products":{"type":"array","items":{"type":"object","properties":{"status":{"type":"string","enum":["pending","processing","complete","failed","cancelled"],"description":"The item's own outcome: `complete` once bought, `failed` once it could not be, `cancelled` when the purchase was cancelled before it was bought. It stays `processing` while it is being bought, for up to an hour before it settles.","isRequired":true,"uniqueKey":"products.items.[INDEX].status","typeLabel":"enum\u003cstring>"},"link":{"type":"string","format":"uri","isRequired":true,"uniqueKey":"products.items.[INDEX].link","typeLabel":"string\u003curi>"},"quantity":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991,"isRequired":true,"uniqueKey":"products.items.[INDEX].quantity","typeLabel":"integer"},"merchant":{"type":"string","isRequired":true,"uniqueKey":"products.items.[INDEX].merchant","typeLabel":"string"},"host":{"type":"string","isRequired":true,"uniqueKey":"products.items.[INDEX].host","typeLabel":"string"},"affiliateProductLink":{"type":"string","format":"uri","uniqueKey":"products.items.[INDEX].affiliateProductLink","typeLabel":"string\u003curi>"},"selectedOptions":{"type":"array","items":{"type":"string","uniqueKey":"products.items.[INDEX].selectedOptions.items.[INDEX]","typeLabel":"string"},"uniqueKey":"products.items.[INDEX].selectedOptions","typeLabel":"string[]"},"selectedShipping":{"type":"object","properties":{"id":{"type":"string","uniqueKey":"products.items.[INDEX].selectedShipping.id","typeLabel":"string"},"value":{"type":"string","uniqueKey":"products.items.[INDEX].selectedShipping.value","typeLabel":"string"}},"additionalProperties":false,"uniqueKey":"products.items.[INDEX].selectedShipping","typeLabel":"object"}},"required":["status","link","quantity","merchant","host"],"additionalProperties":false,"uniqueKey":"products.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"products","typeLabel":"object[]"},"details":{"type":"object","properties":{"hasAccount":{"type":"boolean","isRequired":true,"uniqueKey":"details.hasAccount","typeLabel":"boolean"},"name":{"type":"object","properties":{"firstName":{"type":"string","isRequired":true,"uniqueKey":"details.name.firstName","typeLabel":"string"},"lastName":{"type":"string","isRequired":true,"uniqueKey":"details.name.lastName","typeLabel":"string"},"middleName":{"type":"string","uniqueKey":"details.name.middleName","typeLabel":"string"}},"required":["firstName","lastName"],"additionalProperties":false,"isRequired":true,"uniqueKey":"details.name","typeLabel":"object"},"card":{"type":"object","properties":{"nameOnCard":{"type":"object","properties":{"firstName":{"type":"string","isRequired":true,"uniqueKey":"details.card.nameOnCard.firstName","typeLabel":"string"},"lastName":{"type":"string","isRequired":true,"uniqueKey":"details.card.nameOnCard.lastName","typeLabel":"string"},"middleName":{"type":"string","uniqueKey":"details.card.nameOnCard.middleName","typeLabel":"string"}},"required":["firstName","lastName"],"additionalProperties":false,"isRequired":true,"uniqueKey":"details.card.nameOnCard","typeLabel":"object"},"details":{"type":"object","properties":{},"additionalProperties":false,"isRequired":true,"uniqueKey":"details.card.details","typeLabel":"object"},"billingAddress":{"type":"object","properties":{"line1":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.line1","typeLabel":"string"},"city":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.city","typeLabel":"string"},"province":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.province","typeLabel":"string"},"postalCode":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.postalCode","typeLabel":"string"},"countryCode":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.countryCode","typeLabel":"string"},"name":{"type":"object","properties":{"firstName":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.name.firstName","typeLabel":"string"},"lastName":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.name.lastName","typeLabel":"string"},"middleName":{"type":"string","uniqueKey":"details.card.billingAddress.name.middleName","typeLabel":"string"}},"required":["firstName","lastName"],"additionalProperties":false,"uniqueKey":"details.card.billingAddress.name","typeLabel":"object"},"email":{"type":"string","format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$","uniqueKey":"details.card.billingAddress.email","typeLabel":"string\u003cemail>"},"phone":{"type":"object","properties":{"countryCode":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.phone.countryCode","typeLabel":"string"},"nationalNumber":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.phone.nationalNumber","typeLabel":"string"},"e164":{"type":"string","isRequired":true,"uniqueKey":"details.card.billingAddress.phone.e164","typeLabel":"string"},"country":{"type":"string","uniqueKey":"details.card.billingAddress.phone.country","typeLabel":"string"}},"required":["countryCode","nationalNumber","e164"],"additionalProperties":false,"uniqueKey":"details.card.billingAddress.phone","typeLabel":"object"},"line2":{"type":"string","uniqueKey":"details.card.billingAddress.line2","typeLabel":"string"}},"required":["line1","city","province","postalCode","countryCode"],"additionalProperties":false,"uniqueKey":"details.card.billingAddress","typeLabel":"object"}},"required":["nameOnCard","details"],"additionalProperties":false,"isRequired":true,"uniqueKey":"details.card","typeLabel":"object"},"email":{"type":"string","uniqueKey":"details.email","typeLabel":"string"},"phone":{"type":"object","properties":{"countryCode":{"type":"string","isRequired":true,"uniqueKey":"details.phone.countryCode","typeLabel":"string"},"nationalNumber":{"type":"string","isRequired":true,"uniqueKey":"details.phone.nationalNumber","typeLabel":"string"},"e164":{"type":"string","isRequired":true,"uniqueKey":"details.phone.e164","typeLabel":"string"},"country":{"type":"string","uniqueKey":"details.phone.country","typeLabel":"string"}},"required":["countryCode","nationalNumber","e164"],"additionalProperties":false,"uniqueKey":"details.phone","typeLabel":"object"},"shippingAddress":{"type":"object","properties":{"line1":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.line1","typeLabel":"string"},"city":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.city","typeLabel":"string"},"province":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.province","typeLabel":"string"},"postalCode":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.postalCode","typeLabel":"string"},"countryCode":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.countryCode","typeLabel":"string"},"name":{"type":"object","properties":{"firstName":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.name.firstName","typeLabel":"string"},"lastName":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.name.lastName","typeLabel":"string"},"middleName":{"type":"string","uniqueKey":"details.shippingAddress.name.middleName","typeLabel":"string"}},"required":["firstName","lastName"],"additionalProperties":false,"uniqueKey":"details.shippingAddress.name","typeLabel":"object"},"email":{"type":"string","format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$","uniqueKey":"details.shippingAddress.email","typeLabel":"string\u003cemail>"},"phone":{"type":"object","properties":{"countryCode":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.phone.countryCode","typeLabel":"string"},"nationalNumber":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.phone.nationalNumber","typeLabel":"string"},"e164":{"type":"string","isRequired":true,"uniqueKey":"details.shippingAddress.phone.e164","typeLabel":"string"},"country":{"type":"string","uniqueKey":"details.shippingAddress.phone.country","typeLabel":"string"}},"required":["countryCode","nationalNumber","e164"],"additionalProperties":false,"uniqueKey":"details.shippingAddress.phone","typeLabel":"object"},"line2":{"type":"string","uniqueKey":"details.shippingAddress.line2","typeLabel":"string"}},"required":["line1","city","province","postalCode","countryCode"],"additionalProperties":false,"uniqueKey":"details.shippingAddress","typeLabel":"object"},"settings":{"type":"object","properties":{"collectEmail":{"type":"boolean","uniqueKey":"details.settings.collectEmail","typeLabel":"boolean"},"collectAddress":{"type":"boolean","uniqueKey":"details.settings.collectAddress","typeLabel":"boolean"},"collectPhone":{"type":"boolean","uniqueKey":"details.settings.collectPhone","typeLabel":"boolean"}},"additionalProperties":false,"uniqueKey":"details.settings","typeLabel":"object"}},"required":["hasAccount","name","card"],"additionalProperties":false,"isRequired":true,"uniqueKey":"details","typeLabel":"object"},"inputRequests":{"type":"array","items":{"oneOf":[{"type":"object","required":["type","id","reason","message","merchant","host","lastAnswerRejected","expiresAt","code"],"properties":{"type":{"type":"string","const":"code","description":"A code the store sent the buyer. Answer with the code as a string.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.type","typeLabel":"string"},"id":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The request's id. Answer it with Cart Purchase Input.","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.id","typeLabel":"string"},"reason":{"type":"string","enum":["account_verification","payment_verification","order_change"],"description":"Why the store is asking. `account_verification`: to confirm that the buyer is the one signing in to their account at the store. `payment_verification`: to approve the payment; this one comes from the buyer's bank. `order_change`: something about the order changed and the buyer has to agree to it.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.reason","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"What to show the buyer: the store's own words when they could be read from its page, otherwise a standard sentence for the request.","example":"For your security, we texted a 6-digit code to the phone number ending in 34.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.message","typeLabel":"string"},"merchant":{"type":"string","description":"The store that is asking, as in `products[].merchant`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.merchant","typeLabel":"string"},"host":{"type":"string","description":"That store's host, as in `products[].host`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.host","typeLabel":"string"},"lastAnswerRejected":{"type":"boolean","description":"`true` when the store refused the answer given to the request before this one, and this request asks for a new one.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.lastAnswerRejected","typeLabel":"boolean"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"When the request stops taking an answer. If it passes unanswered, that store's items fail.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.expiresAt","typeLabel":"string\u003cdate-time>"},"code":{"type":"object","properties":{"length":{"description":"How many characters the store's code box takes, when its page shows that. A hint for drawing the input, not a rule: the store judges the code.","type":"integer","minimum":-9007199254740991,"maximum":9007199254740991,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.code.length","typeLabel":"integer"},"sentVia":{"description":"How the store says it sent the code: `sms`, `email`, or `app` for an authenticator app.","type":"string","enum":["sms","email","app"],"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.code.sentVia","typeLabel":"enum\u003cstring>"}},"additionalProperties":false,"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0.code","typeLabel":"object"}},"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.0","typeLabel":"object"},{"type":"object","required":["type","id","reason","message","merchant","host","lastAnswerRejected","expiresAt"],"properties":{"type":{"type":"string","const":"approval","description":"Something the buyer approves on their own device, such as a sign-in notification. It takes no answer: show `message`, and the purchase goes on once they approve.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.type","typeLabel":"string"},"id":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The request's id. Answer it with Cart Purchase Input.","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.id","typeLabel":"string"},"reason":{"type":"string","enum":["account_verification","payment_verification","order_change"],"description":"Why the store is asking. `account_verification`: to confirm that the buyer is the one signing in to their account at the store. `payment_verification`: to approve the payment; this one comes from the buyer's bank. `order_change`: something about the order changed and the buyer has to agree to it.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.reason","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"What to show the buyer: the store's own words when they could be read from its page, otherwise a standard sentence for the request.","example":"For your security, we texted a 6-digit code to the phone number ending in 34.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.message","typeLabel":"string"},"merchant":{"type":"string","description":"The store that is asking, as in `products[].merchant`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.merchant","typeLabel":"string"},"host":{"type":"string","description":"That store's host, as in `products[].host`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.host","typeLabel":"string"},"lastAnswerRejected":{"type":"boolean","description":"`true` when the store refused the answer given to the request before this one, and this request asks for a new one.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.lastAnswerRejected","typeLabel":"boolean"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"When the request stops taking an answer. If it passes unanswered, that store's items fail.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1.expiresAt","typeLabel":"string\u003cdate-time>"}},"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.1","typeLabel":"object"},{"type":"object","required":["type","id","reason","message","merchant","host","lastAnswerRejected","expiresAt","text"],"properties":{"type":{"type":"string","const":"text","description":"Something the buyer knows. Answer with one line of text, at most `text.maxLength` characters.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.type","typeLabel":"string"},"id":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The request's id. Answer it with Cart Purchase Input.","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.id","typeLabel":"string"},"reason":{"type":"string","enum":["account_verification","payment_verification","order_change"],"description":"Why the store is asking. `account_verification`: to confirm that the buyer is the one signing in to their account at the store. `payment_verification`: to approve the payment; this one comes from the buyer's bank. `order_change`: something about the order changed and the buyer has to agree to it.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.reason","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"What to show the buyer: the store's own words when they could be read from its page, otherwise a standard sentence for the request.","example":"For your security, we texted a 6-digit code to the phone number ending in 34.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.message","typeLabel":"string"},"merchant":{"type":"string","description":"The store that is asking, as in `products[].merchant`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.merchant","typeLabel":"string"},"host":{"type":"string","description":"That store's host, as in `products[].host`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.host","typeLabel":"string"},"lastAnswerRejected":{"type":"boolean","description":"`true` when the store refused the answer given to the request before this one, and this request asks for a new one.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.lastAnswerRejected","typeLabel":"boolean"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"When the request stops taking an answer. If it passes unanswered, that store's items fail.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.expiresAt","typeLabel":"string\u003cdate-time>"},"text":{"type":"object","properties":{"maxLength":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991,"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.text.maxLength","typeLabel":"integer"}},"required":["maxLength"],"additionalProperties":false,"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2.text","typeLabel":"object"}},"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.2","typeLabel":"object"},{"type":"object","required":["type","id","reason","message","merchant","host","lastAnswerRejected","expiresAt","options"],"properties":{"type":{"type":"string","const":"choice","description":"One of the options the store shows. Answer with the `id` of the option the buyer picked.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.type","typeLabel":"string"},"id":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The request's id. Answer it with Cart Purchase Input.","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.id","typeLabel":"string"},"reason":{"type":"string","enum":["account_verification","payment_verification","order_change"],"description":"Why the store is asking. `account_verification`: to confirm that the buyer is the one signing in to their account at the store. `payment_verification`: to approve the payment; this one comes from the buyer's bank. `order_change`: something about the order changed and the buyer has to agree to it.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.reason","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"What to show the buyer: the store's own words when they could be read from its page, otherwise a standard sentence for the request.","example":"For your security, we texted a 6-digit code to the phone number ending in 34.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.message","typeLabel":"string"},"merchant":{"type":"string","description":"The store that is asking, as in `products[].merchant`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.merchant","typeLabel":"string"},"host":{"type":"string","description":"That store's host, as in `products[].host`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.host","typeLabel":"string"},"lastAnswerRejected":{"type":"boolean","description":"`true` when the store refused the answer given to the request before this one, and this request asks for a new one.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.lastAnswerRejected","typeLabel":"boolean"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"When the request stops taking an answer. If it passes unanswered, that store's items fail.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.expiresAt","typeLabel":"string\u003cdate-time>"},"options":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.options.items.[INDEX].id","typeLabel":"string"},"label":{"type":"string","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.options.items.[INDEX].label","typeLabel":"string"}},"required":["id","label"],"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.options.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.options","typeLabel":"object[]"},"replaces":{"description":"Present when the store cannot supply an option the buyer ordered for one of the items, and `options` are the ones it still has. The last option, whose `id` is `none`, declines them all: that item is then not bought.","type":"object","properties":{"item":{"type":"object","properties":{"link":{"type":"string","format":"uri","description":"The item's product link, as in `products[].link`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.replaces.item.link","typeLabel":"string\u003curi>"},"name":{"description":"The product's name, when known.","type":"string","uniqueKey":"inputRequests.items.[INDEX].oneOf.3.replaces.item.name","typeLabel":"string"}},"required":["link"],"additionalProperties":false,"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.replaces.item","typeLabel":"object"},"value":{"type":"string","description":"The value the buyer ordered.","example":"M","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.replaces.value","typeLabel":"string"},"label":{"description":"Which option it is, when known.","example":"Size","type":"string","uniqueKey":"inputRequests.items.[INDEX].oneOf.3.replaces.label","typeLabel":"string"}},"required":["item","value"],"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3.replaces","typeLabel":"object"}},"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.3","typeLabel":"object"},{"type":"object","required":["type","id","reason","message","merchant","host","lastAnswerRejected","expiresAt"],"properties":{"type":{"type":"string","const":"confirm","description":"A yes or a no. Answer with `true` or `false`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.type","typeLabel":"string"},"id":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The request's id. Answer it with Cart Purchase Input.","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.id","typeLabel":"string"},"reason":{"type":"string","enum":["account_verification","payment_verification","order_change"],"description":"Why the store is asking. `account_verification`: to confirm that the buyer is the one signing in to their account at the store. `payment_verification`: to approve the payment; this one comes from the buyer's bank. `order_change`: something about the order changed and the buyer has to agree to it.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.reason","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"What to show the buyer: the store's own words when they could be read from its page, otherwise a standard sentence for the request.","example":"For your security, we texted a 6-digit code to the phone number ending in 34.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.message","typeLabel":"string"},"merchant":{"type":"string","description":"The store that is asking, as in `products[].merchant`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.merchant","typeLabel":"string"},"host":{"type":"string","description":"That store's host, as in `products[].host`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.host","typeLabel":"string"},"lastAnswerRejected":{"type":"boolean","description":"`true` when the store refused the answer given to the request before this one, and this request asks for a new one.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.lastAnswerRejected","typeLabel":"boolean"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"When the request stops taking an answer. If it passes unanswered, that store's items fail.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.expiresAt","typeLabel":"string\u003cdate-time>"},"price":{"description":"Present when the buyer is asked to accept a price that went up for one of the items. `true` buys it at the new price; `false` ends the purchase with nothing bought. With no answer before `expiresAt`, the item is bought at the store's price.","type":"object","properties":{"item":{"type":"object","properties":{"link":{"type":"string","format":"uri","description":"The item's product link, as in `products[].link`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.item.link","typeLabel":"string\u003curi>"},"name":{"description":"The product's name, when known.","type":"string","uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.item.name","typeLabel":"string"}},"required":["link"],"additionalProperties":false,"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.item","typeLabel":"object"},"was":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.was.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.was.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"description":"The price of one the buyer was shown.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.was","typeLabel":"object"},"now":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.now.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.now.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"description":"The price of one at the store now.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price.now","typeLabel":"object"}},"required":["item","was","now"],"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4.price","typeLabel":"object"}},"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.4","typeLabel":"object"},{"type":"object","required":["type","id","reason","message","merchant","host","lastAnswerRejected","expiresAt","url"],"properties":{"type":{"type":"string","const":"link","description":"A page the buyer finishes on another site. It takes no answer: send the buyer to `url`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.type","typeLabel":"string"},"id":{"type":"string","pattern":"^[a-zA-Z]{3}-ref_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[0-9a-f]{4}$","description":"The request's id. Answer it with Cart Purchase Input.","example":"inp-ref_3fa85f64-5717-4562-b3fc","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.id","typeLabel":"string"},"reason":{"type":"string","enum":["account_verification","payment_verification","order_change"],"description":"Why the store is asking. `account_verification`: to confirm that the buyer is the one signing in to their account at the store. `payment_verification`: to approve the payment; this one comes from the buyer's bank. `order_change`: something about the order changed and the buyer has to agree to it.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.reason","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"What to show the buyer: the store's own words when they could be read from its page, otherwise a standard sentence for the request.","example":"For your security, we texted a 6-digit code to the phone number ending in 34.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.message","typeLabel":"string"},"merchant":{"type":"string","description":"The store that is asking, as in `products[].merchant`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.merchant","typeLabel":"string"},"host":{"type":"string","description":"That store's host, as in `products[].host`.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.host","typeLabel":"string"},"lastAnswerRejected":{"type":"boolean","description":"`true` when the store refused the answer given to the request before this one, and this request asks for a new one.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.lastAnswerRejected","typeLabel":"boolean"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"When the request stops taking an answer. If it passes unanswered, that store's items fail.","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.expiresAt","typeLabel":"string\u003cdate-time>"},"url":{"type":"string","format":"uri","isRequired":true,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5.url","typeLabel":"string\u003curi>"}},"additionalProperties":false,"uniqueKey":"inputRequests.items.[INDEX].oneOf.5","typeLabel":"object"}],"uniqueKey":"inputRequests.items.[INDEX]","typeLabel":"object"},"description":"What the purchase is waiting on the buyer for, while it is `processing`: most often a code a store sent them. Show each request's `message` to the buyer and answer it with Cart Purchase Input before its `expiresAt`. Empty when the purchase is waiting on nothing, which is nearly always, and always when the purchase was made with `allowInputRequests: false`.","isRequired":true,"uniqueKey":"inputRequests","typeLabel":"object[]"},"result":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"productLink":{"type":"string","format":"uri","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].productLink","typeLabel":"string\u003curi>"},"confirmationNumber":{"type":"string","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].confirmationNumber","typeLabel":"string"},"costs":{"type":"object","properties":{"total":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.total.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.total.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.total","typeLabel":"object"},"subtotal":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.subtotal.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.subtotal.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].costs.subtotal","typeLabel":"object"},"tax":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.tax.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.tax.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].costs.tax","typeLabel":"object"},"shipping":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.shipping.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.shipping.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].costs.shipping","typeLabel":"object"},"discount":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.discount.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs.discount.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].costs.discount","typeLabel":"object"}},"required":["total"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].costs","typeLabel":"object"},"quantity":{"oneOf":[{"type":"integer","maximum":9007199254740991,"minimum":0,"exclusiveMinimum":true,"uniqueKey":"result.\\items.items.[INDEX].quantity.oneOf.0","typeLabel":"integer"},{"type":"null","uniqueKey":"result.\\items.items.[INDEX].quantity.oneOf.1","typeLabel":"null"}],"uniqueKey":"result.\\items.items.[INDEX].quantity","typeLabel":"integer | null"},"shipping":{"type":"object","properties":{"id":{"type":"string","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].shipping.id","typeLabel":"string"},"name":{"type":"string","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].shipping.name","typeLabel":"string"},"cost":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].shipping.cost.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].shipping.cost.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].shipping.cost","typeLabel":"object"},"timeEstimate":{"type":"string","uniqueKey":"result.\\items.items.[INDEX].shipping.timeEstimate","typeLabel":"string"},"minDate":{"type":"string","uniqueKey":"result.\\items.items.[INDEX].shipping.minDate","typeLabel":"string"},"maxDate":{"type":"string","uniqueKey":"result.\\items.items.[INDEX].shipping.maxDate","typeLabel":"string"}},"required":["id","name","cost"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].shipping","typeLabel":"object"},"appliedCoupon":{"type":"object","properties":{"code":{"type":"string","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].appliedCoupon.code","typeLabel":"string"},"savedAmount":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].appliedCoupon.savedAmount.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.\\items.items.[INDEX].appliedCoupon.savedAmount.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].appliedCoupon.savedAmount","typeLabel":"object"}},"required":["code"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX].appliedCoupon","typeLabel":"object"},"metadata":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"oneOf":[{}],"uniqueKey":"result.\\items.items.[INDEX].metadata.additionalProperties","typeLabel":"any"},"uniqueKey":"result.\\items.items.[INDEX].metadata","typeLabel":"object"}},"required":["productLink","confirmationNumber","costs"],"additionalProperties":false,"uniqueKey":"result.\\items.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"result.\\items","typeLabel":"object[]"},"costs":{"type":"object","properties":{"subtotal":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.costs.subtotal.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.costs.subtotal.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.costs.subtotal","typeLabel":"object"},"serviceFee":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.costs.serviceFee.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.costs.serviceFee.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.costs.serviceFee","typeLabel":"object"},"total":{"type":"object","properties":{"value":{"type":"number","isRequired":true,"uniqueKey":"result.costs.total.value","typeLabel":"number"},"currency":{"type":"string","enum":["USD","EUR","AUD","SGD","TWD","GBP","CAD","MXN","NPR","INR","DKK","NOK","SEK","CHF","PLN","CZK","JPY","NZD","HKD","AED","LBP","SAR"],"isRequired":true,"uniqueKey":"result.costs.total.currency","typeLabel":"enum\u003cstring>"}},"required":["value","currency"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.costs.total","typeLabel":"object"}},"required":["subtotal","serviceFee","total"],"additionalProperties":false,"isRequired":true,"uniqueKey":"result.costs","typeLabel":"object"}},"required":["items","costs"],"additionalProperties":false,"uniqueKey":"result","typeLabel":"object"},"error":{"description":"Why items failed, once the order has settled as `failed` or `partially_complete`. Absent while the purchase runs and when every item was bought.","type":"object","properties":{"code":{"type":"string","enum":["CARD_DECLINED","ITEM_UNAVAILABLE","SHIPPING_UNAVAILABLE","MINIMUM_ORDER_NOT_MET","ACCOUNT_LOGIN_FAILED","GMAIL_REQUIRED","INPUT_NOT_PROVIDED","ORDER_CHANGE_DECLINED","PURCHASE_FAILED","MULTIPLE_ERRORS"],"description":"`CARD_DECLINED` — the merchant did not accept the card; a different card may work. `ITEM_UNAVAILABLE` — an item is out of stock or no longer sold. `SHIPPING_UNAVAILABLE` — the merchant does not ship to the address. `MINIMUM_ORDER_NOT_MET` — the order is under the merchant's minimum. `ACCOUNT_LOGIN_FAILED` — the merchant would not sign in to the buyer's own account: no login is connected for them there, the password was rejected or the account is locked, or the merchant asked for a verification only the buyer can complete; ask the buyer to check their login at the merchant and connect it again (`account.connect`). `GMAIL_REQUIRED` — the merchant emailed a sign-in code to the buyer's own account and the buyer's Gmail is not connected (or its access was removed), so the code could not be read; hand the buyer `gmail.connectUrl` from `account.list` and purchase again once they have connected it. `INPUT_NOT_PROVIDED` — the merchant asked the buyer for something through an input request, most often a code it sent them, and no answer it accepted came before the request expired; purchase again and answer the request when it appears in `inputRequests`. `ORDER_CHANGE_DECLINED` — the buyer was asked through an input request to accept a change to the order, an item that now costs more than they were shown, and said no; nothing was bought from that merchant. `PURCHASE_FAILED` — the purchase could not be completed for a reason on Henry's side; contact support with the reference ID. `MULTIPLE_ERRORS` — the order's merchants failed for different reasons.","example":"CARD_DECLINED","isRequired":true,"uniqueKey":"error.code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"A short description of the failure, safe to show the buyer. `PURCHASE_FAILED` and `MULTIPLE_ERRORS` carry the order's reference ID for support.","example":"The merchant did not accept the card","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"required":["code","message"],"additionalProperties":false,"uniqueKey":"error","typeLabel":"object"}},"required":["refId","status","products","details","inputRequests"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"refId":"\u003cstring>","status":"pending","products":[{"status":"pending","link":"\u003cstring>","quantity":123,"merchant":"\u003cstring>","host":"\u003cstring>","affiliateProductLink":"\u003cstring>","selectedOptions":["\u003cstring>"],"selectedShipping":{"id":"\u003cstring>","value":"\u003cstring>"}}],"details":{"hasAccount":true,"name":{"firstName":"\u003cstring>","lastName":"\u003cstring>","middleName":"\u003cstring>"},"card":{"nameOnCard":{"firstName":"\u003cstring>","lastName":"\u003cstring>","middleName":"\u003cstring>"},"details":{},"billingAddress":{"line1":"\u003cstring>","city":"\u003cstring>","province":"\u003cstring>","postalCode":"\u003cstring>","countryCode":"\u003cstring>","name":{"firstName":"\u003cstring>","lastName":"\u003cstring>","middleName":"\u003cstring>"},"email":"jsmith@example.com","phone":{"countryCode":"\u003cstring>","nationalNumber":"\u003cstring>","e164":"\u003cstring>","country":"\u003cstring>"},"line2":"\u003cstring>"}},"email":"\u003cstring>","phone":{"countryCode":"\u003cstring>","nationalNumber":"\u003cstring>","e164":"\u003cstring>","country":"\u003cstring>"},"shippingAddress":{"line1":"\u003cstring>","city":"\u003cstring>","province":"\u003cstring>","postalCode":"\u003cstring>","countryCode":"\u003cstring>","name":{"firstName":"\u003cstring>","lastName":"\u003cstring>","middleName":"\u003cstring>"},"email":"jsmith@example.com","phone":{"countryCode":"\u003cstring>","nationalNumber":"\u003cstring>","e164":"\u003cstring>","country":"\u003cstring>"},"line2":"\u003cstring>"},"settings":{"collectEmail":true,"collectAddress":true,"collectPhone":true}},"inputRequests":[{"type":"code","id":"inp-ref_3fa85f64-5717-4562-b3fc","reason":"account_verification","message":"For your security, we texted a 6-digit code to the phone number ending in 34.","merchant":"\u003cstring>","host":"\u003cstring>","lastAnswerRejected":true,"expiresAt":"2023-11-07T05:31:56Z","code":{"length":0,"sentVia":"sms"}}],"result":{"items":[{"productLink":"\u003cstring>","confirmationNumber":"\u003cstring>","costs":{"total":{"value":123,"currency":"USD"},"subtotal":{"value":123,"currency":"USD"},"tax":{"value":123,"currency":"USD"},"shipping":{"value":123,"currency":"USD"},"discount":{"value":123,"currency":"USD"}},"quantity":4503599627370495,"shipping":{"id":"\u003cstring>","name":"\u003cstring>","cost":{"value":123,"currency":"USD"},"timeEstimate":"\u003cstring>","minDate":"\u003cstring>","maxDate":"\u003cstring>"},"appliedCoupon":{"code":"\u003cstring>","savedAmount":{"value":123,"currency":"USD"}},"metadata":{}}],"costs":{"subtotal":{"value":123,"currency":"USD"},"serviceFee":{"value":123,"currency":"USD"},"total":{"value":123,"currency":"USD"}}},"error":{"code":"CARD_DECLINED","message":"The merchant did not accept the card"}}}},"exampleType":"generated"}},"exampleType":"generated"},"95632215-6933-4420-87c2-1662695c679d":{"description":"Bad request: the value does not fit the request, or the request takes no answer","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"status":{"type":"string","isRequired":true,"uniqueKey":"status","typeLabel":"string"},"message":{"type":"string","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"required":["success","status","message"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":true,"status":"\u003cstring>","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"2154f128-fff9-4a6e-a4c4-09c97cf83300":{"description":"Unauthorized - Invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"status":{"type":"string","isRequired":true,"uniqueKey":"status","typeLabel":"string"},"message":{"type":"string","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"required":["success","status","message"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":true,"status":"\u003cstring>","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"81205669-9c8a-4cf2-8ee8-ffac84496d0c":{"description":"Input request not found","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"status":{"type":"string","isRequired":true,"uniqueKey":"status","typeLabel":"string"},"message":{"type":"string","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"required":["success","status","message"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":true,"status":"\u003cstring>","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"88532171-82bf-4c22-94f9-7abb57648514":{"description":"The request can no longer be answered: it was already answered, it expired, or the purchase moved on without it","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","isRequired":true,"uniqueKey":"success","typeLabel":"boolean"},"status":{"type":"string","isRequired":true,"uniqueKey":"status","typeLabel":"string"},"message":{"type":"string","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"required":["success","status","message"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"success":true,"status":"\u003cstring>","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"2e218555-ce8e-430f-8265-c31f1226f7ef":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-api-key","scopes":[],"schemeName":"ApiKeyAuth"}}},"servers":{"54422345-6881-415a-94f8-63946d7dcab9":{"url":"https://api.henrylabs.ai/v1","description":"Production server"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"x-api-key","scopes":[],"schemeName":"ApiKeyAuth"},"schema":{"title":"x-api-key","type":"string","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKeyAuth","name":"x-api-key"}],"title":"ApiKeyAuth"}]},"originalFileLocation":"v1/api-reference/openapi.documented.json"},"subdomain":"henrysocial","siteName":"Henry Docs","title":"Cart Purchase Input - Henry Docs","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{"v1.20.0":{"href":"/api-reference/cart/cart-purchase-input","matchLevel":0}},"firstHrefInLanguage":{}},"lastModified":"2026-11-27T22:26:00.109Z","originalFileLocation":"api-reference/cart/cart-purchase-input.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in inputRequests on Cart Purchase Status, each with an expiresAt. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with lastAnswerRejected: true.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Henry Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Cart Purchase Input - Henry Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in inputRequests on Cart Purchase Status, each with an expiresAt. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with lastAnswerRejected: true.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Henry Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://henrysocial.mintlify.site/_mintlify/api/og/v2?division=Cart\u0026amp;title=Cart+Purchase+Input\u0026amp;description=Answer+an+input+request%3A+something+a+store+asked+the+buyer+for+while+the+purchase+was+running%2C+most+often+a+code+it+sent+them.+Open+requests+are+listed+in+%60inpu\u0026amp;theme=593e8ea9004f18adfde72362\u0026amp;signature=c97957773f847d943475b07920a5957660985ccd10c246a1febfed0c478d67ef\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Cart Purchase Input - Henry Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in inputRequests on Cart Purchase Status, each with an expiresAt. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with lastAnswerRejected: true.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://henrysocial.mintlify.site/_mintlify/api/og/v2?division=Cart\u0026amp;title=Cart+Purchase+Input\u0026amp;description=Answer+an+input+request%3A+something+a+store+asked+the+buyer+for+while+the+purchase+was+running%2C+most+often+a+code+it+sent+them.+Open+requests+are+listed+in+%60inpu\u0026amp;theme=593e8ea9004f18adfde72362\u0026amp;signature=c97957773f847d943475b07920a5957660985ccd10c246a1febfed0c478d67ef\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/henrysocial/mZMyMeEof-j9j0zV/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Henry Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#F95D24\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/cart/cart-purchase-input.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.henrylabs.ai/#organization\",\"name\":\"Henry Docs\",\"url\":\"https://docs.henrylabs.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/henrysocial/Hwbu9SUy5nEnx_Uc/images/logo-light.svg?fit=max\u0026auto=format\u0026n=Hwbu9SUy5nEnx_Uc\u0026q=85\u0026s=3b5de7db65089f45a1db621b6ffa9a88\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.henrylabs.ai#website\",\"name\":\"Henry Docs\",\"url\":\"https://docs.henrylabs.ai\",\"publisher\":{\"@id\":\"https://docs.henrylabs.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input#webpage\",\"url\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input\",\"name\":\"Cart Purchase Input\",\"description\":\"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in inputRequests on Cart Purchase Status, each with an expiresAt. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with lastAnswerRejected: true.\",\"dateModified\":\"2026-11-27T22:26:00.109Z\",\"isPartOf\":{\"@id\":\"https://docs.henrylabs.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Cart\",\"item\":\"https://docs.henrylabs.ai/api-reference/cart/cart-list\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Cart Purchase Input\",\"item\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input#apireference\",\"headline\":\"Cart Purchase Input\",\"name\":\"Cart Purchase Input\",\"description\":\"Answer an input request: something a store asked the buyer for while the purchase was running, most often a code it sent them. Open requests are listed in inputRequests on Cart Purchase Status, each with an expiresAt. The purchase goes on with the answer, and the order is returned. A request takes one answer: if the store refuses it, a new request follows with lastAnswerRejected: true.\",\"url\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input\",\"mainEntityOfPage\":{\"@id\":\"https://docs.henrylabs.ai/api-reference/cart/cart-purchase-input#webpage\"},\"dateModified\":\"2026-11-27T22:26:00.109Z\",\"publisher\":{\"@id\":\"https://docs.henrylabs.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.henrylabs.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Henry Docs\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Henry Docs\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/cart/cart-purchase-input.md","siteName":"Henry Docs","nav":{"global":null,"versions":[{"version":"v1.20.0","tabs":[{"tab":"Server SDK","pages":[{"title":"Server SDK","href":"/v1/sdk/server/getting-started/introduction"}]},{"tab":"Client SDK","pages":[{"title":"Client SDK","href":"/v1/sdk/client/getting-started/introduction"}]},{"tab":"API Reference","groups":[{"group":"Account","pages":[{"title":"Account Connect","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /account/connect","href":"/api-reference/account/account-connect"},{"title":"Account Connect Link","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /account/connect-link","href":"/api-reference/account/account-connect-link"},{"title":"Account Disconnect","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /account/disconnect","href":"/api-reference/account/account-disconnect"},{"title":"Account List","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /account/list","href":"/api-reference/account/account-list"}]},{"group":"Card","pages":[{"title":"Card Get (Beta)","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /card/{cardToken}","href":"/api-reference/card/card-get-beta"},{"title":"Card Close (Beta)","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /card/{cardToken}/close","href":"/api-reference/card/card-close-beta"},{"title":"Card Issue (Beta)","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /card/issue","href":"/api-reference/card/card-issue-beta"},{"title":"Card Reveal (Beta)","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /card/{cardToken}/reveal","href":"/api-reference/card/card-reveal-beta"},{"title":"Card Tokenize","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /card/tokenize","href":"/api-reference/card/card-tokenize"},{"title":"Card Update","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /card/{cardToken}/cvv","href":"/api-reference/card/card-update"}]},{"group":"Product","pages":[{"title":"Product Details Status","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /product/details/status","href":"/api-reference/product/product-details-status"},{"title":"Product Search Status","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /product/search/status","href":"/api-reference/product/product-search-status"},{"title":"Product Search","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /product/search","href":"/api-reference/product/product-search"},{"title":"Product Details","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /product/details","href":"/api-reference/product/product-details"}]},{"group":"Cart","pages":[{"title":"Cart List","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /cart","href":"/api-reference/cart/cart-list"},{"title":"Cart Create","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart","href":"/api-reference/cart/cart-create"},{"title":"Cart Update Item","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json put /cart/{cartId}/item","href":"/api-reference/cart/cart-update-item"},{"title":"Cart Add Item","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/{cartId}/item","href":"/api-reference/cart/cart-add-item"},{"title":"Cart Remove item","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json delete /cart/{cartId}/item","href":"/api-reference/cart/cart-remove-item"},{"title":"Cart Fetch","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/{cartId}","href":"/api-reference/cart/cart-fetch"},{"title":"Cart Delete","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json delete /cart/{cartId}","href":"/api-reference/cart/cart-delete"},{"title":"Cart Details Status","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /cart/checkout/status","href":"/api-reference/cart/cart-details-status"},{"title":"Cart Details","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/{cartId}/details","href":"/api-reference/cart/cart-details"},{"title":"Cart Purchase Status","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /cart/purchase/status","href":"/api-reference/cart/cart-purchase-status"},{"title":"Cart Purchase Cancel","description":"Stop a purchase that has not bought anything yet: nothing is bought and the order settles as `cancelled`. Allowed while the order is `pending` / `processing`; on most stores, at any point before payment is submitted. An order that bought anything or already settled as `failed` answers `409`, as does one that cannot be stopped at that moment, most often because payment is being submitted (the order's status then shows the outcome, and an order still `processing` afterwards can be cancelled again); cancelling an already cancelled order returns it unchanged.","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/purchase/cancel","href":"/api-reference/cart/cart-purchase-cancel"},{"title":"Cart Purchase Input","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/purchase/input","href":"/api-reference/cart/cart-purchase-input"},{"title":"Cart Purchase","description":"Initiate the purchase process for a cart. Requests are async by default, or use mode=sync to wait up to 30 seconds for completion.","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json post /cart/{cartId}/purchase","href":"/api-reference/cart/cart-purchase"}]},{"group":"Merchants","pages":[{"title":"Merchants List","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /merchants","href":"/api-reference/merchants/merchants-list"},{"title":"Merchant Retrieve","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /merchants/{host}","href":"/api-reference/merchants/merchant-retrieve"},{"title":"Merchant Search","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /merchants/search","href":"/api-reference/merchants/merchant-search"}]},{"group":"Orders","pages":[{"title":"Orders List","deprecated":null,"version":null,"openapi":"/v1/api-reference/openapi.documented.json get /orders","href":"/api-reference/orders/orders-list"}]}]},{"tab":"Changelog","pages":[{"title":"Changelog","href":"/v1/info/changelog"}]},{"tab":"Careers","pages":[{"title":"Careers","href":"/v1/info/careers/join-us"}]}]}]},"basePath":"","title":"Cart Purchase Input - Henry Docs","deploymentId":"dpl_QQ3G2kinQNQFFK6Sh8dmX2teK74w","buildId":"dpl_QQ3G2kinQNQFFK6Sh8dmX2teK74w","dynamics":["c2aa737661","b0f84f53ff","a9bb46feb3","2b790eda92"],"chunks":["OpenApiReferenceProvider-CyAr6xD1.js","snippetPresets-BSqedH3o.js","utils-DXfQSZU_.js","style-to-object-BY3JEAdk.js","utils-DiMyLQC-.js","v4-DIgz8zy6.js","addTypeLabelsToSchema-DvPCxzT8.js","conditional-requirements-CFM0id0Q.js","cloneDeep-dx7iM-7h.js","_Uint8Array-DpQIK2Aw.js","isObject-FP1Yky1u.js","Page-wigwbDGe.js","api-description-markdown-DHZIfeWZ.js","DynamicMarkdown-D8KwOkxZ.js","CodeSnippet-C87it1Zg.js","use-playground-group-access-DyECiQ2v.js","SectionHeading-uish4Ed2.js","ApiExamples-B2sy5qvP.js","usePlaygroundInputsStore-BDc5FJKB.js","shallow-DxZq5uhD.js","isEqual-Bl_IuwU4.js","CodeSnippets-D1UoeS-I.js","MethodPill-DR7O5MCP.js","getPastedJson-D2WQib0m.js","Check2Icon-CUuzblYS.js","axios-CsQoIw0U.js","Markdown-K6_WYP3x.js","AssistantPageLink-BrppVW5v.js","dist-OmDnwAnM.js","lib-DMeTj1gb.js","lib-B8HbPgcC.js","katex-Dbtb6Wk7.js","html-void-elements-mCSPHezU.js","marked.esm-CZWythHk.js"]}