[{"data":1,"prerenderedAt":1198},["ShallowReactive",2],{"navigation_docs":3,"-packages-fluent-python-checkouts":465,"-packages-fluent-python-checkouts-surround":1193},[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":467,"body":468,"description":1186,"extension":1187,"links":1188,"meta":1189,"navigation":1190,"path":384,"seo":1191,"stem":385,"__hash__":1192},"docs\u002F3.packages\u002F7.fluent-python\u002F04.checkouts.md","Create hosted checkouts",{"type":469,"value":470,"toc":1182},"minimark",[471,492,497,876,883,887,1045,1056,1159,1170,1178],[472,473,474,475,479,480,483,484,487,488,491],"p",{},"Build a cart, then call ",[476,477,478],"code",{},"create()"," to make the API request. The result is a full\nSDK Checkout with Fluent's ",[476,481,482],{},"get_url()"," convenience. Pass the configured\n",[476,485,486],{},"vatly"," from ",[489,490,173],"a",{"href":375}," to these functions.",[493,494,496],"h2",{"id":495},"sell-a-one-off-or-mixed-cart","Sell a one-off or mixed cart",[498,499,504],"pre",{"className":500,"code":501,"language":502,"meta":503,"style":503},"language-python shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","from vatly import RequestOptions\nfrom vatly_fluent import CustomerProfile, EntityRef, Vatly\n\n\nasync def example(vatly: Vatly):\n    checkout = (\n        await vatly.checkout_builder(CustomerProfile(vatly_id=\"customer_example\"))\n        .with_items(\n            [\n                {\"id\": \"one_off_product_example\", \"quantity\": 2},\n                {\"id\": \"subscription_plan_example\", \"quantity\": 1},\n            ]\n        )\n        .with_metadata({\"purchaseId\": \"42\"})\n        .for_entity(EntityRef(\"team\", \"42\"))\n        .create(options=RequestOptions(idempotency_key=\"purchase:42\"))\n    )\n    return checkout.id, checkout.get_url()\n","python","",[476,505,506,525,550,557,562,591,603,642,654,660,701,736,742,748,778,810,844,850],{"__ignoreMap":503},[507,508,511,515,519,522],"span",{"class":509,"line":510},"line",1,[507,512,514],{"class":513},"s7zQu","from",[507,516,518],{"class":517},"sTEyZ"," vatly ",[507,520,521],{"class":513},"import",[507,523,524],{"class":517}," RequestOptions\n",[507,526,528,530,533,535,538,542,545,547],{"class":509,"line":527},2,[507,529,514],{"class":513},[507,531,532],{"class":517}," vatly_fluent ",[507,534,521],{"class":513},[507,536,537],{"class":517}," CustomerProfile",[507,539,541],{"class":540},"sMK4o",",",[507,543,544],{"class":517}," EntityRef",[507,546,541],{"class":540},[507,548,549],{"class":517}," Vatly\n",[507,551,553],{"class":509,"line":552},3,[507,554,556],{"emptyLinePlaceholder":555},true,"\n",[507,558,560],{"class":509,"line":559},4,[507,561,556],{"emptyLinePlaceholder":555},[507,563,565,569,572,576,579,582,585,588],{"class":509,"line":564},5,[507,566,568],{"class":567},"spNyl","async",[507,570,571],{"class":567}," def",[507,573,575],{"class":574},"s2Zo4"," example",[507,577,578],{"class":540},"(",[507,580,486],{"class":581},"sHdIc",[507,583,584],{"class":540},":",[507,586,587],{"class":517}," Vatly",[507,589,590],{"class":540},"):\n",[507,592,594,597,600],{"class":509,"line":593},6,[507,595,596],{"class":517},"    checkout ",[507,598,599],{"class":540},"=",[507,601,602],{"class":540}," (\n",[507,604,606,609,612,615,618,620,623,625,628,630,633,637,639],{"class":509,"line":605},7,[507,607,608],{"class":513},"        await",[507,610,611],{"class":517}," vatly",[507,613,614],{"class":540},".",[507,616,617],{"class":574},"checkout_builder",[507,619,578],{"class":540},[507,621,622],{"class":574},"CustomerProfile",[507,624,578],{"class":540},[507,626,627],{"class":581},"vatly_id",[507,629,599],{"class":540},[507,631,632],{"class":540},"\"",[507,634,636],{"class":635},"sfazB","customer_example",[507,638,632],{"class":540},[507,640,641],{"class":540},"))\n",[507,643,645,648,651],{"class":509,"line":644},8,[507,646,647],{"class":540},"        .",[507,649,650],{"class":574},"with_items",[507,652,653],{"class":540},"(\n",[507,655,657],{"class":509,"line":656},9,[507,658,659],{"class":540},"            [\n",[507,661,663,666,668,671,673,675,678,681,683,685,687,690,692,694,698],{"class":509,"line":662},10,[507,664,665],{"class":540},"                {",[507,667,632],{"class":540},[507,669,670],{"class":635},"id",[507,672,632],{"class":540},[507,674,584],{"class":540},[507,676,677],{"class":540}," \"",[507,679,680],{"class":635},"one_off_product_example",[507,682,632],{"class":540},[507,684,541],{"class":540},[507,686,677],{"class":540},[507,688,689],{"class":635},"quantity",[507,691,632],{"class":540},[507,693,584],{"class":540},[507,695,697],{"class":696},"sbssI"," 2",[507,699,700],{"class":540},"},\n",[507,702,704,706,708,710,712,714,716,719,721,723,725,727,729,731,734],{"class":509,"line":703},11,[507,705,665],{"class":540},[507,707,632],{"class":540},[507,709,670],{"class":635},[507,711,632],{"class":540},[507,713,584],{"class":540},[507,715,677],{"class":540},[507,717,718],{"class":635},"subscription_plan_example",[507,720,632],{"class":540},[507,722,541],{"class":540},[507,724,677],{"class":540},[507,726,689],{"class":635},[507,728,632],{"class":540},[507,730,584],{"class":540},[507,732,733],{"class":696}," 1",[507,735,700],{"class":540},[507,737,739],{"class":509,"line":738},12,[507,740,741],{"class":540},"            ]\n",[507,743,745],{"class":509,"line":744},13,[507,746,747],{"class":540},"        )\n",[507,749,751,753,756,759,761,764,766,768,770,773,775],{"class":509,"line":750},14,[507,752,647],{"class":540},[507,754,755],{"class":574},"with_metadata",[507,757,758],{"class":540},"({",[507,760,632],{"class":540},[507,762,763],{"class":635},"purchaseId",[507,765,632],{"class":540},[507,767,584],{"class":540},[507,769,677],{"class":540},[507,771,772],{"class":635},"42",[507,774,632],{"class":540},[507,776,777],{"class":540},"})\n",[507,779,781,783,786,788,791,793,795,798,800,802,804,806,808],{"class":509,"line":780},15,[507,782,647],{"class":540},[507,784,785],{"class":574},"for_entity",[507,787,578],{"class":540},[507,789,790],{"class":574},"EntityRef",[507,792,578],{"class":540},[507,794,632],{"class":540},[507,796,797],{"class":635},"team",[507,799,632],{"class":540},[507,801,541],{"class":540},[507,803,677],{"class":540},[507,805,772],{"class":635},[507,807,632],{"class":540},[507,809,641],{"class":540},[507,811,813,815,818,820,823,825,828,830,833,835,837,840,842],{"class":509,"line":812},16,[507,814,647],{"class":540},[507,816,817],{"class":574},"create",[507,819,578],{"class":540},[507,821,822],{"class":581},"options",[507,824,599],{"class":540},[507,826,827],{"class":574},"RequestOptions",[507,829,578],{"class":540},[507,831,832],{"class":581},"idempotency_key",[507,834,599],{"class":540},[507,836,632],{"class":540},[507,838,839],{"class":635},"purchase:42",[507,841,632],{"class":540},[507,843,641],{"class":540},[507,845,847],{"class":509,"line":846},17,[507,848,849],{"class":540},"    )\n",[507,851,853,856,859,861,864,866,868,870,873],{"class":509,"line":852},18,[507,854,855],{"class":513},"    return",[507,857,858],{"class":517}," checkout",[507,860,614],{"class":540},[507,862,670],{"class":863},"swJcz",[507,865,541],{"class":540},[507,867,858],{"class":517},[507,869,614],{"class":540},[507,871,872],{"class":574},"get_url",[507,874,875],{"class":540},"()\n",[472,877,878,879,882],{},"The customer and entity must already be authorized. Omit the profile for a guest\ncheckout. ",[476,880,881],{},".for_entity()"," needs the checkout-record driver.",[493,884,886],{"id":885},"start-a-subscription-with-a-trial","Start a subscription with a trial",[498,888,890],{"className":500,"code":889,"language":502,"meta":503,"style":503},"from vatly import RequestOptions\nfrom vatly_fluent import Vatly\n\n\nasync def example(vatly: Vatly):\n    return (\n        await vatly.subscribe()\n        .to_plan(\"subscription_plan_example\")\n        .with_quantity(3)\n        .with_trial_days(14)\n        .in_testmode()\n        .create(options=RequestOptions(idempotency_key=\"trial:42\"))\n    )\n",[476,891,892,902,912,916,920,938,944,957,975,989,1003,1012,1041],{"__ignoreMap":503},[507,893,894,896,898,900],{"class":509,"line":510},[507,895,514],{"class":513},[507,897,518],{"class":517},[507,899,521],{"class":513},[507,901,524],{"class":517},[507,903,904,906,908,910],{"class":509,"line":527},[507,905,514],{"class":513},[507,907,532],{"class":517},[507,909,521],{"class":513},[507,911,549],{"class":517},[507,913,914],{"class":509,"line":552},[507,915,556],{"emptyLinePlaceholder":555},[507,917,918],{"class":509,"line":559},[507,919,556],{"emptyLinePlaceholder":555},[507,921,922,924,926,928,930,932,934,936],{"class":509,"line":564},[507,923,568],{"class":567},[507,925,571],{"class":567},[507,927,575],{"class":574},[507,929,578],{"class":540},[507,931,486],{"class":581},[507,933,584],{"class":540},[507,935,587],{"class":517},[507,937,590],{"class":540},[507,939,940,942],{"class":509,"line":593},[507,941,855],{"class":513},[507,943,602],{"class":540},[507,945,946,948,950,952,955],{"class":509,"line":605},[507,947,608],{"class":513},[507,949,611],{"class":517},[507,951,614],{"class":540},[507,953,954],{"class":574},"subscribe",[507,956,875],{"class":540},[507,958,959,961,964,966,968,970,972],{"class":509,"line":644},[507,960,647],{"class":540},[507,962,963],{"class":574},"to_plan",[507,965,578],{"class":540},[507,967,632],{"class":540},[507,969,718],{"class":635},[507,971,632],{"class":540},[507,973,974],{"class":540},")\n",[507,976,977,979,982,984,987],{"class":509,"line":656},[507,978,647],{"class":540},[507,980,981],{"class":574},"with_quantity",[507,983,578],{"class":540},[507,985,986],{"class":696},"3",[507,988,974],{"class":540},[507,990,991,993,996,998,1001],{"class":509,"line":662},[507,992,647],{"class":540},[507,994,995],{"class":574},"with_trial_days",[507,997,578],{"class":540},[507,999,1000],{"class":696},"14",[507,1002,974],{"class":540},[507,1004,1005,1007,1010],{"class":509,"line":703},[507,1006,647],{"class":540},[507,1008,1009],{"class":574},"in_testmode",[507,1011,875],{"class":540},[507,1013,1014,1016,1018,1020,1022,1024,1026,1028,1030,1032,1034,1037,1039],{"class":509,"line":738},[507,1015,647],{"class":540},[507,1017,817],{"class":574},[507,1019,578],{"class":540},[507,1021,822],{"class":581},[507,1023,599],{"class":540},[507,1025,827],{"class":574},[507,1027,578],{"class":540},[507,1029,832],{"class":581},[507,1031,599],{"class":540},[507,1033,632],{"class":540},[507,1035,1036],{"class":635},"trial:42",[507,1038,632],{"class":540},[507,1040,641],{"class":540},[507,1042,1043],{"class":509,"line":744},[507,1044,849],{"class":540},[472,1046,1047,1050,1051,1055],{},[476,1048,1049],{},"subscribe().create()"," creates a ",[1052,1053,1054],"strong",{},"checkout",", not an immediate subscription.\nUse the general builder for mixed carts. Reusing a subscription builder replaces\nits plan item rather than appending another.",[1057,1058,1059,1072],"table",{},[1060,1061,1062],"thead",{},[1063,1064,1065,1069],"tr",{},[1066,1067,1068],"th",{},"Builder method",[1066,1070,1071],{},"Purpose",[1073,1074,1075,1085,1097,1109,1122,1137,1147],"tbody",{},[1063,1076,1077,1082],{},[1078,1079,1080],"td",{},[476,1081,650],{},[1078,1083,1084],{},"Append detached cart items",[1063,1086,1087,1094],{},[1078,1088,1089,1091,1092],{},[476,1090,963],{},", ",[476,1093,981],{},[1078,1095,1096],{},"Select one plan and a positive integer quantity",[1063,1098,1099,1106],{},[1078,1100,1101,1091,1103],{},[476,1102,995],{},[476,1104,1105],{},"with_trial_ends_at",[1078,1107,1108],{},"Trial length or aware deadline, rounded up to whole days",[1063,1110,1111,1119],{},[1078,1112,1113,1091,1116],{},[476,1114,1115],{},"with_redirect_url_success",[476,1117,1118],{},"with_redirect_url_canceled",[1078,1120,1121],{},"Override default redirects",[1063,1123,1124,1134],{},[1078,1125,1126,1091,1129,1091,1131],{},[476,1127,1128],{},"with_locale",[476,1130,755],{},[476,1132,1133],{},"with_billing_address",[1078,1135,1136],{},"Add checkout details",[1063,1138,1139,1144],{},[1078,1140,1141],{},[476,1142,1143],{},"payload",[1078,1145,1146],{},"Inspect a detached wire-format dictionary without a request",[1063,1148,1149,1156],{},[1078,1150,1151,1091,1153],{},[476,1152,1009],{},[476,1154,1155],{},"in_live_mode",[1078,1157,1158],{},"Assert the existing key's mode",[472,1160,1161,1162,1165,1166,1169],{},"Store the purchase key before the API call and reuse it after ambiguous failures,\nincluding a local-save failure after remote success. The redirect does not prove\npayment; use ",[489,1163,1164],{"href":396},"webhooks",". Read lines through ",[476,1167,1168],{},"checkout.order_id","'s Order.",[472,1171,1172],{},[489,1173,1177],{"href":1174,"rel":1175},"https:\u002F\u002Fdocs.vatly.com\u002Fapi-reference\u002Fcheckouts",[1176],"nofollow","Checkout API reference",[1179,1180,1181],"style",{},"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 .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 .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .sHdIc, html code.shiki .sHdIc{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#EEFFFF;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}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);}",{"title":503,"searchDepth":527,"depth":527,"links":1183},[1184,1185],{"id":495,"depth":527,"text":496},{"id":885,"depth":527,"text":886},"Build a cart, then call create() to make the API request.","md",null,{},{"title":80},{"title":467,"description":1186},"7nFQdcxxbwQx1NpMxVaoSQYinLW0543yNSokzLU-T0s",[1194,1196],{"title":68,"path":381,"stem":382,"description":1195,"children":-1},"Bind a host user to a Vatly billing identity once, then reuse it.",{"title":88,"path":387,"stem":388,"description":1197,"children":-1},"Load a locally owned subscription, authorize its entity, then use a handle for plan changes or cancellation.",1794594932822]