[{"data":1,"prerenderedAt":1356},["ShallowReactive",2],{"navigation_docs":3,"-packages-javascript-customers":465,"-packages-javascript-customers-surround":1351},[4,8,62,115,450],{"title":5,"path":6,"stem":7},"Introduction","\u002Fintroduction","0.introduction",{"title":9,"path":10,"stem":11,"children":12,"page":61},"Guides","\u002Fguides","1.guides",[13,17,21,25,29,33,37,41,45,49,53,57],{"title":14,"path":15,"stem":16},"Quickstart","\u002Fguides\u002Fquickstart","1.guides\u002F1.quickstart",{"title":18,"path":19,"stem":20},"Payouts & Settlement","\u002Fguides\u002Fpayouts","1.guides\u002F10.payouts",{"title":22,"path":23,"stem":24},"Customer Emails","\u002Fguides\u002Fcustomer-emails","1.guides\u002F11.customer-emails",{"title":26,"path":27,"stem":28},"Build your own integration","\u002Fguides\u002Fbuild-your-own-integration","1.guides\u002F2.build-your-own-integration",{"title":30,"path":31,"stem":32},"Selling Workflow","\u002Fguides\u002Fselling-workflow","1.guides\u002F2.selling-workflow",{"title":34,"path":35,"stem":36},"Vatly SDKs","\u002Fguides\u002Fsdks","1.guides\u002F3.sdks",{"title":38,"path":39,"stem":40},"Authentication","\u002Fguides\u002Fauthentication","1.guides\u002F4.authentication",{"title":42,"path":43,"stem":44},"Pagination","\u002Fguides\u002Fpagination","1.guides\u002F5.pagination",{"title":46,"path":47,"stem":48},"Errors","\u002Fguides\u002Ferrors","1.guides\u002F6.errors",{"title":50,"path":51,"stem":52},"Webhooks","\u002Fguides\u002Fwebhooks","1.guides\u002F7.webhooks",{"title":54,"path":55,"stem":56},"Idempotency","\u002Fguides\u002Fidempotency","1.guides\u002F8.idempotency",{"title":58,"path":59,"stem":60},"Testing","\u002Fguides\u002Ftesting","1.guides\u002F9.testing",false,{"title":63,"path":64,"stem":65,"children":66,"page":61},"Api Reference","\u002Fapi-reference","2.api-reference",[67,71,75,79,83,87,91,95,99,103,107,111],{"title":68,"path":69,"stem":70},"Customers","\u002Fapi-reference\u002Fcustomers","2.api-reference\u002F1.customers",{"title":72,"path":73,"stem":74},"Webhook Endpoints","\u002Fapi-reference\u002Fwebhook-endpoints","2.api-reference\u002F10.webhook-endpoints",{"title":76,"path":77,"stem":78},"Test helpers","\u002Fapi-reference\u002Ftest-helpers","2.api-reference\u002F11.test-helpers",{"title":80,"path":81,"stem":82},"Checkouts","\u002Fapi-reference\u002Fcheckouts","2.api-reference\u002F2.checkouts",{"title":84,"path":85,"stem":86},"One-off Products","\u002Fapi-reference\u002Fone-off-products","2.api-reference\u002F3.one-off-products",{"title":88,"path":89,"stem":90},"Subscriptions","\u002Fapi-reference\u002Fsubscriptions","2.api-reference\u002F4.subscriptions",{"title":92,"path":93,"stem":94},"Subscription Plans","\u002Fapi-reference\u002Fsubscription-plans","2.api-reference\u002F5.subscription-plans",{"title":96,"path":97,"stem":98},"Orders","\u002Fapi-reference\u002Forders","2.api-reference\u002F6.orders",{"title":100,"path":101,"stem":102},"Order Refunds","\u002Fapi-reference\u002Frefunds","2.api-reference\u002F7.refunds",{"title":104,"path":105,"stem":106},"Refunds","\u002Fapi-reference\u002Fglobal-refunds","2.api-reference\u002F8.global-refunds",{"title":108,"path":109,"stem":110},"Chargebacks","\u002Fapi-reference\u002Fchargebacks","2.api-reference\u002F9.chargebacks",{"title":112,"path":113,"stem":114},"Webhook Events","\u002Fapi-reference\u002Fwebhook-events","2.api-reference\u002F99.webhook-events",{"title":116,"path":117,"stem":118,"children":119},"Packages","\u002Fpackages","3.packages",[120,122,164,210,244,283,318,366,408],{"title":116,"path":117,"stem":121},"3.packages\u002Findex",{"title":123,"path":124,"stem":125,"children":126,"page":61},"PHP SDK","\u002Fpackages\u002Fphp","3.packages\u002F1.php",[127,131,134,137,140,144,147,151,154,157,160],{"title":128,"path":129,"stem":130},"Getting started","\u002Fpackages\u002Fphp\u002Freadme","3.packages\u002F1.php\u002F00.readme",{"title":68,"path":132,"stem":133},"\u002Fpackages\u002Fphp\u002Fcustomers","3.packages\u002F1.php\u002F02.customers",{"title":80,"path":135,"stem":136},"\u002Fpackages\u002Fphp\u002Fcheckouts","3.packages\u002F1.php\u002F03.checkouts",{"title":88,"path":138,"stem":139},"\u002Fpackages\u002Fphp\u002Fsubscriptions","3.packages\u002F1.php\u002F04.subscriptions",{"title":141,"path":142,"stem":143},"Subscription plans","\u002Fpackages\u002Fphp\u002Fsubscriptionplans","3.packages\u002F1.php\u002F05.subscriptionplans",{"title":96,"path":145,"stem":146},"\u002Fpackages\u002Fphp\u002Forders","3.packages\u002F1.php\u002F06.orders",{"title":148,"path":149,"stem":150},"One-off products","\u002Fpackages\u002Fphp\u002Foneoffproducts","3.packages\u002F1.php\u002F07.oneoffproducts",{"title":104,"path":152,"stem":153},"\u002Fpackages\u002Fphp\u002Frefunds","3.packages\u002F1.php\u002F08.refunds",{"title":108,"path":155,"stem":156},"\u002Fpackages\u002Fphp\u002Fchargebacks","3.packages\u002F1.php\u002F09.chargebacks",{"title":50,"path":158,"stem":159},"\u002Fpackages\u002Fphp\u002Fwebhooks","3.packages\u002F1.php\u002F10.webhooks",{"title":161,"path":162,"stem":163},"Webhook URLs","\u002Fpackages\u002Fphp\u002Fwebhookendpoints","3.packages\u002F1.php\u002F11.webhookendpoints",{"title":165,"path":166,"stem":167,"children":168,"page":61},"PHP Fluent","\u002Fpackages\u002Ffluent-php","3.packages\u002F2.fluent-php",[169,172,176,180,183,186,189,192,196,199,203,207],{"title":128,"path":170,"stem":171},"\u002Fpackages\u002Ffluent-php\u002Freadme","3.packages\u002F2.fluent-php\u002F00.readme",{"title":173,"path":174,"stem":175},"Configuration","\u002Fpackages\u002Ffluent-php\u002Fconfiguration","3.packages\u002F2.fluent-php\u002F01.configuration",{"title":177,"path":178,"stem":179},"Core concepts","\u002Fpackages\u002Ffluent-php\u002Fcoreconcepts","3.packages\u002F2.fluent-php\u002F02.coreconcepts",{"title":68,"path":181,"stem":182},"\u002Fpackages\u002Ffluent-php\u002Fcustomers","3.packages\u002F2.fluent-php\u002F03.customers",{"title":80,"path":184,"stem":185},"\u002Fpackages\u002Ffluent-php\u002Fcheckouts","3.packages\u002F2.fluent-php\u002F04.checkouts",{"title":88,"path":187,"stem":188},"\u002Fpackages\u002Ffluent-php\u002Fsubscriptions","3.packages\u002F2.fluent-php\u002F05.subscriptions",{"title":96,"path":190,"stem":191},"\u002Fpackages\u002Ffluent-php\u002Forders","3.packages\u002F2.fluent-php\u002F06.orders",{"title":193,"path":194,"stem":195},"Customer portal","\u002Fpackages\u002Ffluent-php\u002Fcustomerportal","3.packages\u002F2.fluent-php\u002F07.customerportal",{"title":50,"path":197,"stem":198},"\u002Fpackages\u002Ffluent-php\u002Fwebhooks","3.packages\u002F2.fluent-php\u002F08.webhooks",{"title":200,"path":201,"stem":202},"Webhook event flow","\u002Fpackages\u002Ffluent-php\u002Fwebhook-flow","3.packages\u002F2.fluent-php\u002F09.webhook-flow",{"title":204,"path":205,"stem":206},"Existing tables","\u002Fpackages\u002Ffluent-php\u002Fhost-owns-its-tables","3.packages\u002F2.fluent-php\u002F10.host-owns-its-tables",{"title":58,"path":208,"stem":209},"\u002Fpackages\u002Ffluent-php\u002Ftesting","3.packages\u002F2.fluent-php\u002F11.testing",{"title":211,"path":212,"stem":213,"children":214,"page":61},"Laravel","\u002Fpackages\u002Flaravel","3.packages\u002F3.laravel",[215,218,221,224,227,230,233,236,240],{"title":128,"path":216,"stem":217},"\u002Fpackages\u002Flaravel\u002Freadme","3.packages\u002F3.laravel\u002F00.readme",{"title":173,"path":219,"stem":220},"\u002Fpackages\u002Flaravel\u002Fconfiguration","3.packages\u002F3.laravel\u002F01.configuration",{"title":68,"path":222,"stem":223},"\u002Fpackages\u002Flaravel\u002Fcustomers","3.packages\u002F3.laravel\u002F02.customers",{"title":80,"path":225,"stem":226},"\u002Fpackages\u002Flaravel\u002Fcheckouts","3.packages\u002F3.laravel\u002F03.checkouts",{"title":88,"path":228,"stem":229},"\u002Fpackages\u002Flaravel\u002Fsubscriptions","3.packages\u002F3.laravel\u002F04.subscriptions",{"title":96,"path":231,"stem":232},"\u002Fpackages\u002Flaravel\u002Forders","3.packages\u002F3.laravel\u002F05.orders",{"title":50,"path":234,"stem":235},"\u002Fpackages\u002Flaravel\u002Fwebhooks","3.packages\u002F3.laravel\u002F06.webhooks",{"title":237,"path":238,"stem":239},"Comparison","\u002Fpackages\u002Flaravel\u002Fcomparison","3.packages\u002F3.laravel\u002F07.comparison",{"title":241,"path":242,"stem":243},"Migrating from Cashier","\u002Fpackages\u002Flaravel\u002Fmigrating-to-vatly","3.packages\u002F3.laravel\u002F08.migrating-to-vatly",{"title":245,"path":246,"stem":247,"children":248,"page":61},"JavaScript SDK","\u002Fpackages\u002Fjavascript","3.packages\u002F4.javascript",[249,252,255,258,261,264,267,270,273,276,279],{"title":128,"path":250,"stem":251},"\u002Fpackages\u002Fjavascript\u002Freadme","3.packages\u002F4.javascript\u002F00.readme",{"title":68,"path":253,"stem":254},"\u002Fpackages\u002Fjavascript\u002Fcustomers","3.packages\u002F4.javascript\u002F02.customers",{"title":80,"path":256,"stem":257},"\u002Fpackages\u002Fjavascript\u002Fcheckouts","3.packages\u002F4.javascript\u002F03.checkouts",{"title":88,"path":259,"stem":260},"\u002Fpackages\u002Fjavascript\u002Fsubscriptions","3.packages\u002F4.javascript\u002F04.subscriptions",{"title":141,"path":262,"stem":263},"\u002Fpackages\u002Fjavascript\u002Fsubscriptionplans","3.packages\u002F4.javascript\u002F05.subscriptionplans",{"title":96,"path":265,"stem":266},"\u002Fpackages\u002Fjavascript\u002Forders","3.packages\u002F4.javascript\u002F06.orders",{"title":148,"path":268,"stem":269},"\u002Fpackages\u002Fjavascript\u002Foneoffproducts","3.packages\u002F4.javascript\u002F07.oneoffproducts",{"title":104,"path":271,"stem":272},"\u002Fpackages\u002Fjavascript\u002Frefunds","3.packages\u002F4.javascript\u002F08.refunds",{"title":108,"path":274,"stem":275},"\u002Fpackages\u002Fjavascript\u002Fchargebacks","3.packages\u002F4.javascript\u002F09.chargebacks",{"title":50,"path":277,"stem":278},"\u002Fpackages\u002Fjavascript\u002Fwebhooks","3.packages\u002F4.javascript\u002F10.webhooks",{"title":280,"path":281,"stem":282},"API reference","\u002Fpackages\u002Fjavascript\u002Fapi","3.packages\u002F4.javascript\u002F12.api",{"title":284,"path":285,"stem":286,"children":287,"page":61},"JavaScript Fluent","\u002Fpackages\u002Ffluent-js","3.packages\u002F5.fluent-js",[288,291,294,297,300,303,306,309,312,315],{"title":128,"path":289,"stem":290},"\u002Fpackages\u002Ffluent-js\u002Freadme","3.packages\u002F5.fluent-js\u002F00.readme",{"title":173,"path":292,"stem":293},"\u002Fpackages\u002Ffluent-js\u002Fconfiguration","3.packages\u002F5.fluent-js\u002F01.configuration",{"title":177,"path":295,"stem":296},"\u002Fpackages\u002Ffluent-js\u002Fcoreconcepts","3.packages\u002F5.fluent-js\u002F02.coreconcepts",{"title":68,"path":298,"stem":299},"\u002Fpackages\u002Ffluent-js\u002Fcustomers","3.packages\u002F5.fluent-js\u002F03.customers",{"title":80,"path":301,"stem":302},"\u002Fpackages\u002Ffluent-js\u002Fcheckouts","3.packages\u002F5.fluent-js\u002F04.checkouts",{"title":88,"path":304,"stem":305},"\u002Fpackages\u002Ffluent-js\u002Fsubscriptions","3.packages\u002F5.fluent-js\u002F05.subscriptions",{"title":96,"path":307,"stem":308},"\u002Fpackages\u002Ffluent-js\u002Forders","3.packages\u002F5.fluent-js\u002F06.orders",{"title":193,"path":310,"stem":311},"\u002Fpackages\u002Ffluent-js\u002Fcustomerportal","3.packages\u002F5.fluent-js\u002F07.customerportal",{"title":50,"path":313,"stem":314},"\u002Fpackages\u002Ffluent-js\u002Fwebhooks","3.packages\u002F5.fluent-js\u002F08.webhooks",{"title":58,"path":316,"stem":317},"\u002Fpackages\u002Ffluent-js\u002Ftesting","3.packages\u002F5.fluent-js\u002F11.testing",{"title":319,"path":320,"stem":321,"children":322,"page":61},"Python SDK","\u002Fpackages\u002Fpython","3.packages\u002F6.python",[323,326,329,332,335,338,341,344,347,350,353,356,359,362],{"title":128,"path":324,"stem":325},"\u002Fpackages\u002Fpython\u002Freadme","3.packages\u002F6.python\u002F00.readme",{"title":173,"path":327,"stem":328},"\u002Fpackages\u002Fpython\u002Fconfiguration","3.packages\u002F6.python\u002F01.configuration",{"title":68,"path":330,"stem":331},"\u002Fpackages\u002Fpython\u002Fcustomers","3.packages\u002F6.python\u002F02.customers",{"title":80,"path":333,"stem":334},"\u002Fpackages\u002Fpython\u002Fcheckouts","3.packages\u002F6.python\u002F03.checkouts",{"title":88,"path":336,"stem":337},"\u002Fpackages\u002Fpython\u002Fsubscriptions","3.packages\u002F6.python\u002F04.subscriptions",{"title":141,"path":339,"stem":340},"\u002Fpackages\u002Fpython\u002Fsubscriptionplans","3.packages\u002F6.python\u002F05.subscriptionplans",{"title":96,"path":342,"stem":343},"\u002Fpackages\u002Fpython\u002Forders","3.packages\u002F6.python\u002F06.orders",{"title":148,"path":345,"stem":346},"\u002Fpackages\u002Fpython\u002Foneoffproducts","3.packages\u002F6.python\u002F07.oneoffproducts",{"title":104,"path":348,"stem":349},"\u002Fpackages\u002Fpython\u002Frefunds","3.packages\u002F6.python\u002F08.refunds",{"title":108,"path":351,"stem":352},"\u002Fpackages\u002Fpython\u002Fchargebacks","3.packages\u002F6.python\u002F09.chargebacks",{"title":50,"path":354,"stem":355},"\u002Fpackages\u002Fpython\u002Fwebhooks","3.packages\u002F6.python\u002F10.webhooks",{"title":161,"path":357,"stem":358},"\u002Fpackages\u002Fpython\u002Fwebhookendpoints","3.packages\u002F6.python\u002F11.webhookendpoints",{"title":280,"path":360,"stem":361},"\u002Fpackages\u002Fpython\u002Fapi","3.packages\u002F6.python\u002F12.api",{"title":363,"path":364,"stem":365},"Development","\u002Fpackages\u002Fpython\u002Fdevelopment","3.packages\u002F6.python\u002F13.development",{"title":367,"path":368,"stem":369,"children":370,"page":61},"Python Fluent","\u002Fpackages\u002Ffluent-python","3.packages\u002F7.fluent-python",[371,374,377,380,383,386,389,392,395,398,401,405],{"title":128,"path":372,"stem":373},"\u002Fpackages\u002Ffluent-python\u002Freadme","3.packages\u002F7.fluent-python\u002F00.readme",{"title":173,"path":375,"stem":376},"\u002Fpackages\u002Ffluent-python\u002Fconfiguration","3.packages\u002F7.fluent-python\u002F01.configuration",{"title":177,"path":378,"stem":379},"\u002Fpackages\u002Ffluent-python\u002Fcoreconcepts","3.packages\u002F7.fluent-python\u002F02.coreconcepts",{"title":68,"path":381,"stem":382},"\u002Fpackages\u002Ffluent-python\u002Fcustomers","3.packages\u002F7.fluent-python\u002F03.customers",{"title":80,"path":384,"stem":385},"\u002Fpackages\u002Ffluent-python\u002Fcheckouts","3.packages\u002F7.fluent-python\u002F04.checkouts",{"title":88,"path":387,"stem":388},"\u002Fpackages\u002Ffluent-python\u002Fsubscriptions","3.packages\u002F7.fluent-python\u002F05.subscriptions",{"title":96,"path":390,"stem":391},"\u002Fpackages\u002Ffluent-python\u002Forders","3.packages\u002F7.fluent-python\u002F06.orders",{"title":193,"path":393,"stem":394},"\u002Fpackages\u002Ffluent-python\u002Fcustomerportal","3.packages\u002F7.fluent-python\u002F07.customerportal",{"title":50,"path":396,"stem":397},"\u002Fpackages\u002Ffluent-python\u002Fwebhooks","3.packages\u002F7.fluent-python\u002F08.webhooks",{"title":58,"path":399,"stem":400},"\u002Fpackages\u002Ffluent-python\u002Ftesting","3.packages\u002F7.fluent-python\u002F11.testing",{"title":402,"path":403,"stem":404},"Porting","\u002Fpackages\u002Ffluent-python\u002Fporting","3.packages\u002F7.fluent-python\u002F12.porting",{"title":363,"path":406,"stem":407},"\u002Fpackages\u002Ffluent-python\u002Fdevelopment","3.packages\u002F7.fluent-python\u002F13.development",{"title":409,"path":410,"stem":411,"children":412,"page":61},"Django","\u002Fpackages\u002Fdjango","3.packages\u002F8.django",[413,416,420,423,427,431,434,437,440,444,447],{"title":128,"path":414,"stem":415},"\u002Fpackages\u002Fdjango\u002Freadme","3.packages\u002F8.django\u002F00.readme",{"title":417,"path":418,"stem":419},"Installation","\u002Fpackages\u002Fdjango\u002Finstallation","3.packages\u002F8.django\u002F01.installation",{"title":173,"path":421,"stem":422},"\u002Fpackages\u002Fdjango\u002Fconfiguration","3.packages\u002F8.django\u002F02.configuration",{"title":424,"path":425,"stem":426},"Billable models","\u002Fpackages\u002Fdjango\u002Fbillablemodels","3.packages\u002F8.django\u002F03.billablemodels",{"title":428,"path":429,"stem":430},"Checkout","\u002Fpackages\u002Fdjango\u002Fcheckout","3.packages\u002F8.django\u002F04.checkout",{"title":88,"path":432,"stem":433},"\u002Fpackages\u002Fdjango\u002Fbilling","3.packages\u002F8.django\u002F05.billing",{"title":193,"path":435,"stem":436},"\u002Fpackages\u002Fdjango\u002Fcustomerportal","3.packages\u002F8.django\u002F06.customerportal",{"title":50,"path":438,"stem":439},"\u002Fpackages\u002Fdjango\u002Fwebhooks","3.packages\u002F8.django\u002F07.webhooks",{"title":441,"path":442,"stem":443},"Admin","\u002Fpackages\u002Fdjango\u002Fadmin","3.packages\u002F8.django\u002F08.admin",{"title":58,"path":445,"stem":446},"\u002Fpackages\u002Fdjango\u002Ftesting","3.packages\u002F8.django\u002F09.testing",{"title":363,"path":448,"stem":449},"\u002Fpackages\u002Fdjango\u002Fdevelopment","3.packages\u002F8.django\u002F10.development",{"title":451,"path":452,"stem":453,"children":454},"Integrations","\u002Fintegrations","4.integrations",[455,457,461],{"title":451,"path":452,"stem":456},"4.integrations\u002Findex",{"title":458,"path":459,"stem":460},"Lovable payments with Vatly","\u002Fintegrations\u002Flovable","4.integrations\u002F1.lovable",{"title":462,"path":463,"stem":464},"Bolt payments with Vatly","\u002Fintegrations\u002Fbolt","4.integrations\u002F2.bolt",{"id":466,"title":68,"body":467,"description":473,"extension":1345,"links":1346,"meta":1347,"navigation":1348,"path":253,"seo":1349,"stem":254,"__hash__":1350},"docs\u002F3.packages\u002F4.javascript\u002F02.customers.md",{"type":468,"value":469,"toc":1334},"minimark",[470,474,491,496,615,619,624,629,656,660,688,799,802,861,865,870,909,913,1043,1050,1054,1059,1153,1157,1162,1330],[471,472,473],"p",{},"Customers represent the end users who purchase products through Vatly.",[471,475,476,477,484,485,490],{},"For all fields and options, see the ",[478,479,483],"a",{"href":480,"rel":481},"https:\u002F\u002Fdocs.vatly.com\u002Fapi-reference\u002Fcustomers",[482],"nofollow","Customers API reference",". The ",[478,486,489],{"href":487,"rel":488},"https:\u002F\u002Fdocs.vatly.com\u002Fopenapi.yaml",[482],"OpenAPI spec"," is also available for tooling.",[492,493,495],"h2",{"id":494},"the-customer-resource","The Customer resource",[497,498,499,515],"table",{},[500,501,502],"thead",{},[503,504,505,509,512],"tr",{},[506,507,508],"th",{},"Name",[506,510,511],{},"Type",[506,513,514],{},"Description",[516,517,518,539,557,571,586,600],"tbody",{},[503,519,520,527,532],{},[521,522,523],"td",{},[524,525,526],"code",{},"id",[521,528,529],{},[524,530,531],{},"string",[521,533,534,535,538],{},"Unique identifier for the customer (",[524,536,537],{},"customer_…",").",[503,540,541,546,550],{},[521,542,543],{},[524,544,545],{},"resource",[521,547,548],{},[524,549,531],{},[521,551,552,553,556],{},"Always ",[524,554,555],{},"customer",".",[503,558,559,564,568],{},[521,560,561],{},[524,562,563],{},"email",[521,565,566],{},[524,567,531],{},[521,569,570],{},"Customer's email address (ASCII \u002F Punycode domain).",[503,572,573,578,583],{},[521,574,575],{},[524,576,577],{},"metadata",[521,579,580],{},[524,581,582],{},"object | null",[521,584,585],{},"Your custom key\u002Fvalue metadata.",[503,587,588,593,597],{},[521,589,590],{},[524,591,592],{},"createdAt",[521,594,595],{},[524,596,531],{},[521,598,599],{},"Creation timestamp (ISO 8601).",[503,601,602,607,612],{},[521,603,604],{},[524,605,606],{},"testmode",[521,608,609],{},[524,610,611],{},"boolean",[521,613,614],{},"Whether this is a test customer.",[492,616,618],{"id":617},"create-a-customer","Create a customer",[471,620,621],{},[524,622,623],{},"POST \u002Fv1\u002Fcustomers",[625,626,628],"h3",{"id":627},"required-attributes","Required attributes",[497,630,631,641],{},[500,632,633],{},[503,634,635,637,639],{},[506,636,508],{},[506,638,511],{},[506,640,514],{},[516,642,643],{},[503,644,645,649,653],{},[521,646,647],{},[524,648,563],{},[521,650,651],{},[524,652,531],{},[521,654,655],{},"The customer's email address.",[625,657,659],{"id":658},"optional-attributes","Optional attributes",[497,661,662,672],{},[500,663,664],{},[503,665,666,668,670],{},[506,667,508],{},[506,669,511],{},[506,671,514],{},[516,673,674],{},[503,675,676,680,685],{},[521,677,678],{},[524,679,577],{},[521,681,682],{},[524,683,684],{},"object",[521,686,687],{},"Custom key\u002Fvalue metadata.",[689,690,695],"pre",{"className":691,"code":692,"language":693,"meta":694,"style":694},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","const customer = await vatly.customers.create({\n  email: \"ada@example.com\",\n  metadata: { plan: \"pro\" },\n});\n","ts","",[524,696,697,738,761,787],{"__ignoreMap":694},[698,699,702,706,710,714,718,721,723,726,728,732,735],"span",{"class":700,"line":701},"line",1,[698,703,705],{"class":704},"spNyl","const",[698,707,709],{"class":708},"sTEyZ"," customer ",[698,711,713],{"class":712},"sMK4o","=",[698,715,717],{"class":716},"s7zQu"," await",[698,719,720],{"class":708}," vatly",[698,722,556],{"class":712},[698,724,725],{"class":708},"customers",[698,727,556],{"class":712},[698,729,731],{"class":730},"s2Zo4","create",[698,733,734],{"class":708},"(",[698,736,737],{"class":712},"{\n",[698,739,741,745,748,751,755,758],{"class":700,"line":740},2,[698,742,744],{"class":743},"swJcz","  email",[698,746,747],{"class":712},":",[698,749,750],{"class":712}," \"",[698,752,754],{"class":753},"sfazB","ada@example.com",[698,756,757],{"class":712},"\"",[698,759,760],{"class":712},",\n",[698,762,764,767,769,772,775,777,779,782,784],{"class":700,"line":763},3,[698,765,766],{"class":743},"  metadata",[698,768,747],{"class":712},[698,770,771],{"class":712}," {",[698,773,774],{"class":743}," plan",[698,776,747],{"class":712},[698,778,750],{"class":712},[698,780,781],{"class":753},"pro",[698,783,757],{"class":712},[698,785,786],{"class":712}," },\n",[698,788,790,793,796],{"class":700,"line":789},4,[698,791,792],{"class":712},"}",[698,794,795],{"class":708},")",[698,797,798],{"class":712},";\n",[471,800,801],{},"Unicode domains are accepted directly; Vatly lowercases the local part and\ncanonicalizes the domain to lowercase Punycode. Creating an already-known email\nreturns the existing customer unchanged. To encode a domain yourself, optionally use:",[689,803,805],{"className":691,"code":804,"language":693,"meta":694,"style":694},"import { encodeEmail } from \"@getvatly\u002Fsdk\";\n\nencodeEmail(\"user@bücher.de\"); \u002F\u002F → \"user@xn--bcher-kva.de\"\n",[524,806,807,832,838],{"__ignoreMap":694},[698,808,809,812,814,817,820,823,825,828,830],{"class":700,"line":701},[698,810,811],{"class":716},"import",[698,813,771],{"class":712},[698,815,816],{"class":708}," encodeEmail",[698,818,819],{"class":712}," }",[698,821,822],{"class":716}," from",[698,824,750],{"class":712},[698,826,827],{"class":753},"@getvatly\u002Fsdk",[698,829,757],{"class":712},[698,831,798],{"class":712},[698,833,834],{"class":700,"line":740},[698,835,837],{"emptyLinePlaceholder":836},true,"\n",[698,839,840,843,845,847,850,852,854,857],{"class":700,"line":763},[698,841,842],{"class":730},"encodeEmail",[698,844,734],{"class":708},[698,846,757],{"class":712},[698,848,849],{"class":753},"user@bücher.de",[698,851,757],{"class":712},[698,853,795],{"class":708},[698,855,856],{"class":712},";",[698,858,860],{"class":859},"sHwdD"," \u002F\u002F → \"user@xn--bcher-kva.de\"\n",[492,862,864],{"id":863},"retrieve-a-customer","Retrieve a customer",[471,866,867],{},[524,868,869],{},"GET \u002Fv1\u002Fcustomers\u002F{customerId}",[689,871,873],{"className":691,"code":872,"language":693,"meta":694,"style":694},"const customer = await vatly.customers.get(\"customer_abc123\");\n",[524,874,875],{"__ignoreMap":694},[698,876,877,879,881,883,885,887,889,891,893,896,898,900,903,905,907],{"class":700,"line":701},[698,878,705],{"class":704},[698,880,709],{"class":708},[698,882,713],{"class":712},[698,884,717],{"class":716},[698,886,720],{"class":708},[698,888,556],{"class":712},[698,890,725],{"class":708},[698,892,556],{"class":712},[698,894,895],{"class":730},"get",[698,897,734],{"class":708},[698,899,757],{"class":712},[698,901,902],{"class":753},"customer_abc123",[698,904,757],{"class":712},[698,906,795],{"class":708},[698,908,798],{"class":712},[492,910,912],{"id":911},"update-identity-and-open-the-hosted-portal","Update identity and open the hosted portal",[689,914,916],{"className":691,"code":915,"language":693,"meta":694,"style":694},"await vatly.customers.update(\"customer_abc123\", { name: \"Ada\", email: \"ada@example.com\" });\nconst session = await vatly.customers.createPortalSession(\"customer_abc123\", {\n  returnUrl: \"https:\u002F\u002Fyourapp.com\u002Faccount\",\n});\n\u002F\u002F Redirect the customer's browser to session.url. It is short-lived and single-use.\n",[524,917,918,978,1013,1029,1037],{"__ignoreMap":694},[698,919,920,923,925,927,929,931,934,936,938,940,942,945,947,950,952,954,957,959,961,964,966,968,970,972,974,976],{"class":700,"line":701},[698,921,922],{"class":716},"await",[698,924,720],{"class":708},[698,926,556],{"class":712},[698,928,725],{"class":708},[698,930,556],{"class":712},[698,932,933],{"class":730},"update",[698,935,734],{"class":708},[698,937,757],{"class":712},[698,939,902],{"class":753},[698,941,757],{"class":712},[698,943,944],{"class":712},",",[698,946,771],{"class":712},[698,948,949],{"class":743}," name",[698,951,747],{"class":712},[698,953,750],{"class":712},[698,955,956],{"class":753},"Ada",[698,958,757],{"class":712},[698,960,944],{"class":712},[698,962,963],{"class":743}," email",[698,965,747],{"class":712},[698,967,750],{"class":712},[698,969,754],{"class":753},[698,971,757],{"class":712},[698,973,819],{"class":712},[698,975,795],{"class":708},[698,977,798],{"class":712},[698,979,980,982,985,987,989,991,993,995,997,1000,1002,1004,1006,1008,1010],{"class":700,"line":740},[698,981,705],{"class":704},[698,983,984],{"class":708}," session ",[698,986,713],{"class":712},[698,988,717],{"class":716},[698,990,720],{"class":708},[698,992,556],{"class":712},[698,994,725],{"class":708},[698,996,556],{"class":712},[698,998,999],{"class":730},"createPortalSession",[698,1001,734],{"class":708},[698,1003,757],{"class":712},[698,1005,902],{"class":753},[698,1007,757],{"class":712},[698,1009,944],{"class":712},[698,1011,1012],{"class":712}," {\n",[698,1014,1015,1018,1020,1022,1025,1027],{"class":700,"line":763},[698,1016,1017],{"class":743},"  returnUrl",[698,1019,747],{"class":712},[698,1021,750],{"class":712},[698,1023,1024],{"class":753},"https:\u002F\u002Fyourapp.com\u002Faccount",[698,1026,757],{"class":712},[698,1028,760],{"class":712},[698,1030,1031,1033,1035],{"class":700,"line":789},[698,1032,792],{"class":712},[698,1034,795],{"class":708},[698,1036,798],{"class":712},[698,1038,1040],{"class":700,"line":1039},5,[698,1041,1042],{"class":859},"\u002F\u002F Redirect the customer's browser to session.url. It is short-lived and single-use.\n",[471,1044,1045,1046,1049],{},"Updates accept name\u002Femail, not billing addresses. Portal settings are optional;\n",[524,1047,1048],{},"returnUrl"," must be an absolute HTTPS URL without credentials, sent in the JSON\nbody (not query params), at most 2,048 UTF-8 bytes. Authenticate your own customer\nbefore issuing a portal session, and never log or persist its credential URL.",[492,1051,1053],{"id":1052},"list-customers","List customers",[471,1055,1056],{},[524,1057,1058],{},"GET \u002Fv1\u002Fcustomers",[689,1060,1062],{"className":691,"code":1061,"language":693,"meta":694,"style":694},"const page = await vatly.customers.list({ limit: 25 });\n\nfor await (const customer of vatly.customers.listAll()) {\n  \u002F\u002F ...\n}\n",[524,1063,1064,1106,1110,1143,1148],{"__ignoreMap":694},[698,1065,1066,1068,1071,1073,1075,1077,1079,1081,1083,1086,1088,1091,1094,1096,1100,1102,1104],{"class":700,"line":701},[698,1067,705],{"class":704},[698,1069,1070],{"class":708}," page ",[698,1072,713],{"class":712},[698,1074,717],{"class":716},[698,1076,720],{"class":708},[698,1078,556],{"class":712},[698,1080,725],{"class":708},[698,1082,556],{"class":712},[698,1084,1085],{"class":730},"list",[698,1087,734],{"class":708},[698,1089,1090],{"class":712},"{",[698,1092,1093],{"class":743}," limit",[698,1095,747],{"class":712},[698,1097,1099],{"class":1098},"sbssI"," 25",[698,1101,819],{"class":712},[698,1103,795],{"class":708},[698,1105,798],{"class":712},[698,1107,1108],{"class":700,"line":740},[698,1109,837],{"emptyLinePlaceholder":836},[698,1111,1112,1115,1117,1120,1122,1124,1127,1129,1131,1133,1135,1138,1141],{"class":700,"line":763},[698,1113,1114],{"class":716},"for",[698,1116,717],{"class":716},[698,1118,1119],{"class":708}," (",[698,1121,705],{"class":704},[698,1123,709],{"class":708},[698,1125,1126],{"class":712},"of",[698,1128,720],{"class":708},[698,1130,556],{"class":712},[698,1132,725],{"class":708},[698,1134,556],{"class":712},[698,1136,1137],{"class":730},"listAll",[698,1139,1140],{"class":708},"()) ",[698,1142,737],{"class":712},[698,1144,1145],{"class":700,"line":789},[698,1146,1147],{"class":859},"  \u002F\u002F ...\n",[698,1149,1150],{"class":700,"line":1039},[698,1151,1152],{"class":712},"}\n",[492,1154,1156],{"id":1155},"a-customers-subscriptions","A customer's subscriptions",[471,1158,1159],{},[524,1160,1161],{},"GET \u002Fv1\u002Fcustomers\u002F{customerId}\u002Fsubscriptions",[689,1163,1165],{"className":691,"code":1164,"language":693,"meta":694,"style":694},"\u002F\u002F One page:\nconst page = await vatly.customers.listSubscriptions(\"customer_abc123\", { limit: 10 });\n\n\u002F\u002F Every subscription:\nfor await (const sub of vatly.customers.listAllSubscriptions(\"customer_abc123\")) {\n  \u002F\u002F ...\n}\n\n\u002F\u002F A single nested subscription:\nconst sub = await vatly.customers.getSubscription(\"customer_abc123\", \"subscription_abc123\");\n",[524,1166,1167,1172,1218,1222,1227,1266,1271,1276,1281,1287],{"__ignoreMap":694},[698,1168,1169],{"class":700,"line":701},[698,1170,1171],{"class":859},"\u002F\u002F One page:\n",[698,1173,1174,1176,1178,1180,1182,1184,1186,1188,1190,1193,1195,1197,1199,1201,1203,1205,1207,1209,1212,1214,1216],{"class":700,"line":740},[698,1175,705],{"class":704},[698,1177,1070],{"class":708},[698,1179,713],{"class":712},[698,1181,717],{"class":716},[698,1183,720],{"class":708},[698,1185,556],{"class":712},[698,1187,725],{"class":708},[698,1189,556],{"class":712},[698,1191,1192],{"class":730},"listSubscriptions",[698,1194,734],{"class":708},[698,1196,757],{"class":712},[698,1198,902],{"class":753},[698,1200,757],{"class":712},[698,1202,944],{"class":712},[698,1204,771],{"class":712},[698,1206,1093],{"class":743},[698,1208,747],{"class":712},[698,1210,1211],{"class":1098}," 10",[698,1213,819],{"class":712},[698,1215,795],{"class":708},[698,1217,798],{"class":712},[698,1219,1220],{"class":700,"line":763},[698,1221,837],{"emptyLinePlaceholder":836},[698,1223,1224],{"class":700,"line":789},[698,1225,1226],{"class":859},"\u002F\u002F Every subscription:\n",[698,1228,1229,1231,1233,1235,1237,1240,1242,1244,1246,1248,1250,1253,1255,1257,1259,1261,1264],{"class":700,"line":1039},[698,1230,1114],{"class":716},[698,1232,717],{"class":716},[698,1234,1119],{"class":708},[698,1236,705],{"class":704},[698,1238,1239],{"class":708}," sub ",[698,1241,1126],{"class":712},[698,1243,720],{"class":708},[698,1245,556],{"class":712},[698,1247,725],{"class":708},[698,1249,556],{"class":712},[698,1251,1252],{"class":730},"listAllSubscriptions",[698,1254,734],{"class":708},[698,1256,757],{"class":712},[698,1258,902],{"class":753},[698,1260,757],{"class":712},[698,1262,1263],{"class":708},")) ",[698,1265,737],{"class":712},[698,1267,1269],{"class":700,"line":1268},6,[698,1270,1147],{"class":859},[698,1272,1274],{"class":700,"line":1273},7,[698,1275,1152],{"class":712},[698,1277,1279],{"class":700,"line":1278},8,[698,1280,837],{"emptyLinePlaceholder":836},[698,1282,1284],{"class":700,"line":1283},9,[698,1285,1286],{"class":859},"\u002F\u002F A single nested subscription:\n",[698,1288,1290,1292,1294,1296,1298,1300,1302,1304,1306,1309,1311,1313,1315,1317,1319,1321,1324,1326,1328],{"class":700,"line":1289},10,[698,1291,705],{"class":704},[698,1293,1239],{"class":708},[698,1295,713],{"class":712},[698,1297,717],{"class":716},[698,1299,720],{"class":708},[698,1301,556],{"class":712},[698,1303,725],{"class":708},[698,1305,556],{"class":712},[698,1307,1308],{"class":730},"getSubscription",[698,1310,734],{"class":708},[698,1312,757],{"class":712},[698,1314,902],{"class":753},[698,1316,757],{"class":712},[698,1318,944],{"class":712},[698,1320,750],{"class":712},[698,1322,1323],{"class":753},"subscription_abc123",[698,1325,757],{"class":712},[698,1327,795],{"class":708},[698,1329,798],{"class":712},[1331,1332,1333],"style",{},"html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}",{"title":694,"searchDepth":740,"depth":740,"links":1335},[1336,1337,1341,1342,1343,1344],{"id":494,"depth":740,"text":495},{"id":617,"depth":740,"text":618,"children":1338},[1339,1340],{"id":627,"depth":763,"text":628},{"id":658,"depth":763,"text":659},{"id":863,"depth":740,"text":864},{"id":911,"depth":740,"text":912},{"id":1052,"depth":740,"text":1053},{"id":1155,"depth":740,"text":1156},"md",null,{},{"title":68},{"title":68,"description":473},"4HjDIyVUbKUrY8FaoxeGPKZYmiJwmlwYEUtVPQOGrWk",[1352,1354],{"title":128,"path":250,"stem":251,"description":1353,"children":-1},"Official TypeScript SDK for Vatly, the European Merchant of Record for AI, software and digital products.",{"title":80,"path":256,"stem":257,"description":1355,"children":-1},"Checkouts create hosted payment pages for your customers.",1794594929062]