[{"data":1,"prerenderedAt":1371},["ShallowReactive",2],{"versions":3,"nav-guides":8,"nav-ref-v1":86,"guide-\u002Fguides\u002Fwarranties":618,"guide-around-\u002Fguides\u002Fwarranties":1366},[4],{"id":5,"label":5,"file":6,"status":7},"v1","cartirra-v1.json","current",[9,14,19,24,29,34,39,44,49,55,60,65,70,75,80],{"path":10,"title":11,"group":11,"order":12,"description":13},"\u002Fguides\u002Fgetting-started","Getting started",1,"What the Cartirra API does, how requests look, and the three things to set up first.",{"path":15,"title":16,"group":11,"order":17,"description":18},"\u002Fguides\u002Fquickstart","Quickstart",2,"Create a checkout session from your server, let the shopper pay, and read the order. About ten minutes, all in test mode.",{"path":20,"title":21,"group":11,"order":22,"description":23},"\u002Fguides\u002Fembed-checkout","Cartirra Popup and Redirect",2.5,"Open the checkout over your own page with one script tag (Cartirra Popup), or send shoppers to Cartirra's checkout page (Cartirra Redirect). Then confirm the order on your server.",{"path":25,"title":26,"group":11,"order":27,"description":28},"\u002Fguides\u002Fad-tracking","Track checkouts in your ads",2.6,"Your Meta, Google and TikTok pixels see every checkout step and purchase, in the browser and from Cartirra's server, counted once.",{"path":30,"title":31,"group":11,"order":32,"description":33},"\u002Fguides\u002Fpay-at-table","Pay at table",2.7,"Tables with QR codes, bills guests pay from their phone (all at once or split), the live board, refunds and the day's reconciliation. An add-on, per store.",{"path":35,"title":36,"group":11,"order":37,"description":38},"\u002Fguides\u002Fwarranties","Warranties",2.8,"Give a warranty with an item at checkout, or add one after the sale. The shopper keeps it in their Cartirra account and is reminded before it ends. Growth and above.",{"path":40,"title":41,"group":11,"order":42,"description":43},"\u002Fguides\u002Fauthentication","Authentication",3,"Secret and public keys, test and live mode, rotating keys without downtime, and keeping them safe.",{"path":45,"title":46,"group":11,"order":47,"description":48},"\u002Fguides\u002Ftest-mode","Test mode",4,"Build and test your integration with test keys. Payments, refunds and payouts are simulated; no real money moves.",{"path":50,"title":51,"group":52,"order":53,"description":54},"\u002Fguides\u002Fpagination","Pagination and filtering","Core concepts",10,"Lists are newest first and use cursors. Ask for up to 100 items a page and follow next_cursor.",{"path":56,"title":57,"group":52,"order":58,"description":59},"\u002Fguides\u002Fidempotency","Idempotency",11,"Retry creates and refunds safely. The same Idempotency-Key always gets the same response, and the action happens once.",{"path":61,"title":62,"group":52,"order":63,"description":64},"\u002Fguides\u002Ferrors","Errors and troubleshooting",12,"One error shape everywhere. Branch on code, show message, and quote request_id when you contact support.",{"path":66,"title":67,"group":52,"order":68,"description":69},"\u002Fguides\u002Frate-limits","Rate limits",13,"Each secret key gets its own request budget. Back off on 429 using Retry-After.",{"path":71,"title":72,"group":52,"order":73,"description":74},"\u002Fguides\u002Fversioning","Versioning",14,"The version is in the path. Within v1 we only add things, and anything removed is announced with Deprecation and Sunset headers first.",{"path":76,"title":77,"group":77,"order":78,"description":79},"\u002Fguides\u002Fwebhooks","Webhooks",20,"Cartirra posts signed events to your endpoint when orders, payments, refunds, payouts and customers change. Verify, deduplicate, answer fast.",{"path":81,"title":82,"group":83,"order":84,"description":85},"\u002Fguides\u002Fchangelog","Changelog","Resources",30,"Changes to the Cartirra API and these docs. Within v1, changes are additive only.",{"title":87,"version":88,"tags":89,"webhooks":536},"Cartirra API","1.0.0",[90,112,136,171,239,313,345,355,369,384,409,432,446,456,481,496,511,526],{"name":91,"slug":92,"description":93,"operations":94},"Checkout sessions","checkout-sessions","Open a checkout for a cart; the shopper pays in Cartirra Popup on your page or through Cartirra Redirect.",[95,101,107],{"operationId":96,"slug":97,"method":98,"path":99,"summary":100,"tag":91},"createCheckoutSession","create-checkout-session","post","\u002Fv1\u002Fcheckout-sessions","Create a checkout session",{"operationId":102,"slug":103,"method":104,"path":105,"summary":106,"tag":91},"getCheckoutSession","get-checkout-session","get","\u002Fv1\u002Fcheckout-sessions\u002F{id}","Retrieve a checkout session",{"operationId":108,"slug":109,"method":98,"path":110,"summary":111,"tag":91},"expireCheckoutSession","expire-checkout-session","\u002Fv1\u002Fcheckout-sessions\u002F{id}\u002Fexpire","Expire a checkout session",{"name":113,"slug":114,"description":115,"operations":116},"Payment links","payment-links","Carts you share as a link (WhatsApp, Instagram, SMS): no code needed.",[117,122,126,131],{"operationId":118,"slug":119,"method":104,"path":120,"summary":121,"tag":113},"listPaymentLinks","list-payment-links","\u002Fv1\u002Fpayment-links","List payment links",{"operationId":123,"slug":124,"method":98,"path":120,"summary":125,"tag":113},"createPaymentLink","create-payment-link","Create a payment link",{"operationId":127,"slug":128,"method":104,"path":129,"summary":130,"tag":113},"getPaymentLink","get-payment-link","\u002Fv1\u002Fpayment-links\u002F{id}","Retrieve a payment link",{"operationId":132,"slug":133,"method":134,"path":129,"summary":135,"tag":113},"updatePaymentLink","update-payment-link","patch","Update a payment link",{"name":137,"slug":138,"description":139,"operations":140},"Tables","tables","Pay at table: your tables and the QR code printed on each.",[141,146,152,157,161,166],{"operationId":142,"slug":143,"method":104,"path":144,"summary":145,"tag":137},"listPayAtTableStores","list-pay-at-table-stores","\u002Fv1\u002Fpay-at-table\u002Fstores","List Pay at table stores",{"operationId":147,"slug":148,"method":149,"path":150,"summary":151,"tag":137},"setStorePayAtTable","set-store-pay-at-table","put","\u002Fv1\u002Fstores\u002F{store_id}\u002Fpay-at-table","Turn Pay at table on or off at a store",{"operationId":153,"slug":154,"method":104,"path":155,"summary":156,"tag":137},"listTables","list-tables","\u002Fv1\u002Fstores\u002F{store_id}\u002Ftables","List tables",{"operationId":158,"slug":159,"method":98,"path":155,"summary":160,"tag":137},"createTables","create-tables","Add tables",{"operationId":162,"slug":163,"method":134,"path":164,"summary":165,"tag":137},"updateTable","update-table","\u002Fv1\u002Ftables\u002F{id}","Update a table",{"operationId":167,"slug":168,"method":98,"path":169,"summary":170,"tag":137},"rotateTableQr","rotate-table-qr","\u002Fv1\u002Ftables\u002F{id}\u002Frotate-qr","Replace a table’s QR link",{"name":172,"slug":173,"description":174,"operations":175},"Bills","bills","Pay at table: bills guests pay from the table QR (all at once or split), the live board, refunds and the day’s reconciliation.",[176,181,185,190,195,200,205,210,215,220,224,229,234],{"operationId":177,"slug":178,"method":104,"path":179,"summary":180,"tag":172},"listBills","list-bills","\u002Fv1\u002Fbills","List bills",{"operationId":182,"slug":183,"method":98,"path":179,"summary":184,"tag":172},"openBill","open-bill","Open a bill",{"operationId":186,"slug":187,"method":104,"path":188,"summary":189,"tag":172},"getBillBoard","get-bill-board","\u002Fv1\u002Fbills\u002Fboard","Retrieve the table board",{"operationId":191,"slug":192,"method":104,"path":193,"summary":194,"tag":172},"lookupBillPayments","lookup-bill-payments","\u002Fv1\u002Fbills\u002Fpayments","Find a table payment",{"operationId":196,"slug":197,"method":104,"path":198,"summary":199,"tag":172},"getBillReconciliation","get-bill-reconciliation","\u002Fv1\u002Fbills\u002Freconciliation","Retrieve the day’s reconciliation",{"operationId":201,"slug":202,"method":104,"path":203,"summary":204,"tag":172},"listBillRefunds","list-bill-refunds","\u002Fv1\u002Fbills\u002Frefunds","List the refund queue",{"operationId":206,"slug":207,"method":98,"path":208,"summary":209,"tag":172},"refundBillRefund","refund-bill-refund","\u002Fv1\u002Fbills\u002Frefunds\u002F{id}\u002Frefund","Send a queued refund",{"operationId":211,"slug":212,"method":98,"path":213,"summary":214,"tag":172},"dismissBillRefund","dismiss-bill-refund","\u002Fv1\u002Fbills\u002Frefunds\u002F{id}\u002Fdismiss","Dismiss a queued refund",{"operationId":216,"slug":217,"method":104,"path":218,"summary":219,"tag":172},"getBill","get-bill","\u002Fv1\u002Fbills\u002F{id}","Retrieve a bill",{"operationId":221,"slug":222,"method":134,"path":218,"summary":223,"tag":172},"updateBill","update-bill","Update a bill",{"operationId":225,"slug":226,"method":98,"path":227,"summary":228,"tag":172},"recordBillOutsidePayment","record-bill-outside-payment","\u002Fv1\u002Fbills\u002F{id}\u002Foutside","Record a payment outside Cartirra",{"operationId":230,"slug":231,"method":98,"path":232,"summary":233,"tag":172},"closeBill","close-bill","\u002Fv1\u002Fbills\u002F{id}\u002Fclose","Close a bill",{"operationId":235,"slug":236,"method":98,"path":237,"summary":238,"tag":172},"voidBill","void-bill","\u002Fv1\u002Fbills\u002F{id}\u002Fvoid","Void a bill",{"name":240,"slug":241,"description":242,"operations":243},"Orders","orders","Orders placed through checkout: read them and move them through fulfilment, and answer problems shoppers report.",[244,249,254,259,264,269,274,279,284,289,294,298,303,308],{"operationId":245,"slug":246,"method":104,"path":247,"summary":248,"tag":240},"getOrderRelated","get-order-related","\u002Fv1\u002Forders\u002F{id}\u002Frelated","Retrieve order extras",{"operationId":250,"slug":251,"method":104,"path":252,"summary":253,"tag":240},"listOrders","list-orders","\u002Fv1\u002Forders","List orders",{"operationId":255,"slug":256,"method":104,"path":257,"summary":258,"tag":240},"getOrder","get-order","\u002Fv1\u002Forders\u002F{id}","Retrieve an order",{"operationId":260,"slug":261,"method":104,"path":262,"summary":263,"tag":240},"listOrderActivity","list-order-activity","\u002Fv1\u002Forders\u002F{id}\u002Factivity","List order activity",{"operationId":265,"slug":266,"method":98,"path":267,"summary":268,"tag":240},"updateOrderStatus","update-order-status","\u002Fv1\u002Forders\u002F{id}\u002Fstatus","Update order status",{"operationId":270,"slug":271,"method":98,"path":272,"summary":273,"tag":240},"acceptOrder","accept-order","\u002Fv1\u002Forders\u002F{id}\u002Faccept","Accept an order",{"operationId":275,"slug":276,"method":149,"path":277,"summary":278,"tag":240},"updateOrderDeliveryAddress","update-order-delivery-address","\u002Fv1\u002Forders\u002F{id}\u002Fdelivery-address","Update delivery address",{"operationId":280,"slug":281,"method":98,"path":282,"summary":283,"tag":240},"cancelOrder","cancel-order","\u002Fv1\u002Forders\u002F{id}\u002Fcancel","Cancel an order",{"operationId":285,"slug":286,"method":104,"path":287,"summary":288,"tag":240},"listOrderIssues","list-order-issues","\u002Fv1\u002Forder-issues","List problem reports",{"operationId":290,"slug":291,"method":104,"path":292,"summary":293,"tag":240},"getOrderIssue","get-order-issue","\u002Fv1\u002Forder-issues\u002F{id}","Retrieve a problem report",{"operationId":295,"slug":296,"method":134,"path":292,"summary":297,"tag":240},"updateOrderIssue","update-order-issue","Update a problem report",{"operationId":299,"slug":300,"method":98,"path":301,"summary":302,"tag":240},"markPayOnDeliveryCollected","mark-pay-on-delivery-collected","\u002Fv1\u002Forders\u002F{id}\u002Fpay-on-delivery\u002Fcollected","Mark pay on delivery collected",{"operationId":304,"slug":305,"method":98,"path":306,"summary":307,"tag":240},"markPayOnDeliveryNotPaid","mark-pay-on-delivery-not-paid","\u002Fv1\u002Forders\u002F{id}\u002Fpay-on-delivery\u002Fnot-paid","Mark pay on delivery not paid",{"operationId":309,"slug":310,"method":98,"path":311,"summary":312,"tag":240},"rejectOrder","reject-order","\u002Fv1\u002Forders\u002F{id}\u002Freject","Reject an order",{"name":36,"slug":314,"description":315,"operations":316},"warranties","Warranties on what you sold: sent on checkout lines or added afterwards. Shoppers keep them in their Cartirra account.",[317,322,327,331,336,341],{"operationId":318,"slug":319,"method":104,"path":320,"summary":321,"tag":36},"listWarranties","list-warranties","\u002Fv1\u002Fwarranties","List warranties",{"operationId":323,"slug":324,"method":104,"path":325,"summary":326,"tag":36},"getWarranty","get-warranty","\u002Fv1\u002Fwarranties\u002F{id}","Retrieve a warranty",{"operationId":328,"slug":329,"method":134,"path":325,"summary":330,"tag":36},"updateWarranty","update-warranty","Update a warranty",{"operationId":332,"slug":333,"method":98,"path":334,"summary":335,"tag":36},"voidWarranty","void-warranty","\u002Fv1\u002Fwarranties\u002F{id}\u002Fvoid","Void a warranty",{"operationId":337,"slug":338,"method":104,"path":339,"summary":340,"tag":36},"listOrderWarranties","list-order-warranties","\u002Fv1\u002Forders\u002F{id}\u002Fwarranties","List an order's warranties",{"operationId":342,"slug":343,"method":98,"path":339,"summary":344,"tag":36},"createWarranty","create-warranty","Add a warranty to an order",{"name":346,"slug":347,"description":348,"operations":349},"Payments","payments","The payment behind an order (bank transfer or card).",[350],{"operationId":351,"slug":352,"method":104,"path":353,"summary":354,"tag":346},"getPayment","get-payment","\u002Fv1\u002Fpayments\u002F{id}","Retrieve a payment",{"name":356,"slug":357,"description":358,"operations":359},"Refunds","refunds","Return money to the shopper, in full or in part.",[360,365],{"operationId":361,"slug":362,"method":104,"path":363,"summary":364,"tag":356},"listRefunds","list-refunds","\u002Fv1\u002Forders\u002F{id}\u002Frefunds","List refunds",{"operationId":366,"slug":367,"method":98,"path":363,"summary":368,"tag":356},"createRefund","create-refund","Create a refund",{"name":370,"slug":371,"description":372,"operations":373},"Receipts","receipts","Receipts and credit notes issued for orders.",[374,379],{"operationId":375,"slug":376,"method":104,"path":377,"summary":378,"tag":370},"getOrderReceipt","get-order-receipt","\u002Fv1\u002Forders\u002F{id}\u002Freceipt","Retrieve a receipt",{"operationId":380,"slug":381,"method":104,"path":382,"summary":383,"tag":370},"listOrderCreditNotes","list-order-credit-notes","\u002Fv1\u002Forders\u002F{id}\u002Fcredit-notes","List credit notes",{"name":385,"slug":386,"description":387,"operations":388},"Customers","customers","Shoppers who shared their details with your business.",[389,394,399,404],{"operationId":390,"slug":391,"method":104,"path":392,"summary":393,"tag":385},"listCustomerActivity","list-customer-activity","\u002Fv1\u002Fcustomers\u002F{id}\u002Factivity","List customer activity",{"operationId":395,"slug":396,"method":104,"path":397,"summary":398,"tag":385},"listCustomerAddresses","list-customer-addresses","\u002Fv1\u002Fcustomers\u002F{id}\u002Faddresses","List customer addresses",{"operationId":400,"slug":401,"method":104,"path":402,"summary":403,"tag":385},"listCustomers","list-customers","\u002Fv1\u002Fcustomers","List customers",{"operationId":405,"slug":406,"method":104,"path":407,"summary":408,"tag":385},"getCustomer","get-customer","\u002Fv1\u002Fcustomers\u002F{id}","Retrieve a customer",{"name":410,"slug":411,"description":412,"operations":413},"Promotions","promotions","Discount codes and automatic promotions.",[414,419,423,428],{"operationId":415,"slug":416,"method":104,"path":417,"summary":418,"tag":410},"listPromotions","list-promotions","\u002Fv1\u002Fpromotions","List promotions",{"operationId":420,"slug":421,"method":98,"path":417,"summary":422,"tag":410},"createPromotion","create-promotion","Create a promotion",{"operationId":424,"slug":425,"method":104,"path":426,"summary":427,"tag":410},"getPromotion","get-promotion","\u002Fv1\u002Fpromotions\u002F{id}","Retrieve a promotion",{"operationId":429,"slug":430,"method":134,"path":426,"summary":431,"tag":410},"updatePromotion","update-promotion","Update a promotion",{"name":433,"slug":434,"description":435,"operations":436},"Gift cards","gift-cards","Issue and list gift cards.",[437,442],{"operationId":438,"slug":439,"method":104,"path":440,"summary":441,"tag":433},"listGiftCards","list-gift-cards","\u002Fv1\u002Fgift-cards","List gift cards",{"operationId":443,"slug":444,"method":98,"path":440,"summary":445,"tag":433},"createGiftCard","create-gift-card","Issue a gift card",{"name":447,"slug":448,"description":449,"operations":450},"Reviews","reviews","Ratings shoppers left on completed orders.",[451],{"operationId":452,"slug":453,"method":104,"path":454,"summary":455,"tag":447},"listReviews","list-reviews","\u002Fv1\u002Freviews","List reviews",{"name":457,"slug":458,"description":459,"operations":460},"Balance","balance","Your Cartirra balance and its movements.",[461,466,471,476],{"operationId":462,"slug":463,"method":104,"path":464,"summary":465,"tag":457},"getBalance","get-balance","\u002Fv1\u002Fbalance","Retrieve balance",{"operationId":467,"slug":468,"method":104,"path":469,"summary":470,"tag":457},"listBalanceTransactions","list-balance-transactions","\u002Fv1\u002Fbalance\u002Ftransactions","List balance transactions",{"operationId":472,"slug":473,"method":104,"path":474,"summary":475,"tag":457},"getBalanceTransaction","get-balance-transaction","\u002Fv1\u002Fbalance\u002Ftransactions\u002F{id}","Retrieve a balance transaction",{"operationId":477,"slug":478,"method":104,"path":479,"summary":480,"tag":457},"getDeposit","get-deposit","\u002Fv1\u002Fbalance\u002Fdeposits\u002F{id}","Retrieve a deposit",{"name":482,"slug":483,"description":484,"operations":485},"Payouts","payouts","Money sent from your balance to your bank account.",[486,491],{"operationId":487,"slug":488,"method":104,"path":489,"summary":490,"tag":482},"listPayouts","list-payouts","\u002Fv1\u002Fpayouts","List payouts",{"operationId":492,"slug":493,"method":104,"path":494,"summary":495,"tag":482},"getPayout","get-payout","\u002Fv1\u002Fpayouts\u002F{id}","Retrieve a payout",{"name":497,"slug":498,"description":499,"operations":500},"Stores","stores","Your business's stores.",[501,506],{"operationId":502,"slug":503,"method":104,"path":504,"summary":505,"tag":497},"listStores","list-stores","\u002Fv1\u002Fstores","List stores",{"operationId":507,"slug":508,"method":104,"path":509,"summary":510,"tag":497},"getStore","get-store","\u002Fv1\u002Fstores\u002F{store_id}","Retrieve a store",{"name":512,"slug":513,"description":514,"operations":515},"Events","events","Everything Cartirra sent (or would send) to your webhook endpoint.",[516,521],{"operationId":517,"slug":518,"method":104,"path":519,"summary":520,"tag":512},"listEvents","list-events","\u002Fv1\u002Fevents","List events",{"operationId":522,"slug":523,"method":104,"path":524,"summary":525,"tag":512},"getEvent","get-event","\u002Fv1\u002Fevents\u002F{id}","Retrieve an event",{"name":527,"slug":528,"description":529,"operations":530},"Account","account","The business and mode your key belongs to.",[531],{"operationId":532,"slug":533,"method":104,"path":534,"summary":535,"tag":527},"getContext","get-context","\u002Fv1\u002Fme\u002Fcontext","Retrieve key context",[537,540,543,546,549,552,555,558,561,564,567,570,573,576,579,582,585,588,591,594,597,600,603,606,609,612,615],{"event":538,"slug":539,"summary":538},"order.created","order-created",{"event":541,"slug":542,"summary":541},"order.updated","order-updated",{"event":544,"slug":545,"summary":544},"payment.succeeded","payment-succeeded",{"event":547,"slug":548,"summary":547},"payment.failed","payment-failed",{"event":550,"slug":551,"summary":550},"payment.expired","payment-expired",{"event":553,"slug":554,"summary":553},"refund.succeeded","refund-succeeded",{"event":556,"slug":557,"summary":556},"refund.failed","refund-failed",{"event":559,"slug":560,"summary":559},"payout.paid","payout-paid",{"event":562,"slug":563,"summary":562},"payout.failed","payout-failed",{"event":565,"slug":566,"summary":565},"webhook.test","webhook-test",{"event":568,"slug":569,"summary":568},"customer.created","customer-created",{"event":571,"slug":572,"summary":571},"customer.updated","customer-updated",{"event":574,"slug":575,"summary":574},"bill.opened","bill-opened",{"event":577,"slug":578,"summary":577},"bill.updated","bill-updated",{"event":580,"slug":581,"summary":580},"bill.payment_received","bill-payment-received",{"event":583,"slug":584,"summary":583},"bill.closed","bill-closed",{"event":586,"slug":587,"summary":586},"bill.voided","bill-voided",{"event":589,"slug":590,"summary":589},"customer.consent_revoked","customer-consent-revoked",{"event":592,"slug":593,"summary":592},"order.issue_reported","order-issue-reported",{"event":595,"slug":596,"summary":595},"order.issue_updated","order-issue-updated",{"event":598,"slug":599,"summary":598},"warranty.created","warranty-created",{"event":601,"slug":602,"summary":601},"warranty.updated","warranty-updated",{"event":604,"slug":605,"summary":604},"warranty.voided","warranty-voided",{"event":607,"slug":608,"summary":607},"order.accepted","order-accepted",{"event":610,"slug":611,"summary":610},"order.rejected","order-rejected",{"event":613,"slug":614,"summary":613},"loyalty.tier_changed","loyalty-tier-changed",{"event":616,"slug":617,"summary":616},"loyalty.reward_redeemed","loyalty-reward-redeemed",{"id":619,"title":36,"body":620,"description":38,"extension":1360,"group":11,"meta":1361,"navigation":1362,"order":37,"path":35,"seo":1363,"stem":1364,"__hash__":1365},"guides\u002Fguides\u002Fwarranties.md",{"type":621,"value":622,"toc":1352},"minimark",[623,627,640,645,658,835,912,929,933,940,963,970,974,981,1062,1089,1097,1147,1155,1205,1209,1218,1259,1268,1271,1321,1333,1337,1348],[624,625,626],"p",{},"If you sell phones, appliances, electronics or anything else that comes with a guarantee, Cartirra keeps the warranty for you and for the shopper. You say what the warranty is when you create the checkout session. When the order is paid, the warranty starts. The shopper finds it in their Cartirra account with the receipt, and Cartirra reminds them before it ends.",[624,628,629,630,634,635,639],{},"Warranties need the ",[631,632,633],"strong",{},"Growth"," plan or above. On Starter, a checkout session or payment link with a warranty is refused with ",[636,637,638],"code",{},"feature_not_available",".",[641,642,644],"h2",{"id":643},"_1-add-a-warranty-to-a-checkout-line","1. Add a warranty to a checkout line",[624,646,647,648,653,654,657],{},"When you ",[649,650,652],"a",{"href":651},"\u002Freference\u002Fcreate-checkout-session","create a checkout session",", give each line that comes with a warranty a ",[636,655,656],{},"warranty"," object. Lines without one need nothing.",[659,660,665],"pre",{"className":661,"code":662,"language":663,"meta":664,"style":664},"language-bash shiki shiki-themes github-light github-dark","curl https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Fcheckout-sessions \\\n  -H \"Authorization: Bearer $CARTIRRA_SECRET_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"lines\": [\n      {\n        \"name\": \"Samsung Galaxy A15\",\n        \"quantity\": 1,\n        \"sku\": \"SM-A155\",\n        \"unit_price\": { \"amount\": \"185000.00\", \"currency\": \"NGN\" },\n        \"warranty\": {\n          \"months\": 12,\n          \"covered_by\": \"manufacturer\",\n          \"provider\": \"Samsung Nigeria\",\n          \"terms\": \"Covers faults from manufacture. Not water or screen damage.\"\n        }\n      },\n      {\n        \"name\": \"Phone case\",\n        \"quantity\": 1,\n        \"unit_price\": { \"amount\": \"5000.00\", \"currency\": \"NGN\" }\n      }\n    ],\n    \"success_url\": \"https:\u002F\u002Fshop.example.com\u002Fthanks\"\n  }'\n","bash","",[636,666,667,683,700,709,717,723,729,735,741,747,752,757,762,767,772,778,784,790,795,801,805,811,817,823,829],{"__ignoreMap":664},[668,669,671,675,679],"span",{"class":670,"line":12},"line",[668,672,674],{"class":673},"sScJk","curl",[668,676,678],{"class":677},"sZZnC"," https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Fcheckout-sessions",[668,680,682],{"class":681},"sj4cs"," \\\n",[668,684,685,688,691,695,698],{"class":670,"line":17},[668,686,687],{"class":681},"  -H",[668,689,690],{"class":677}," \"Authorization: Bearer ",[668,692,694],{"class":693},"sVt8B","$CARTIRRA_SECRET_KEY",[668,696,697],{"class":677},"\"",[668,699,682],{"class":681},[668,701,702,704,707],{"class":670,"line":42},[668,703,687],{"class":681},[668,705,706],{"class":677}," \"Content-Type: application\u002Fjson\"",[668,708,682],{"class":681},[668,710,711,714],{"class":670,"line":47},[668,712,713],{"class":681},"  -d",[668,715,716],{"class":677}," '{\n",[668,718,720],{"class":670,"line":719},5,[668,721,722],{"class":677},"    \"lines\": [\n",[668,724,726],{"class":670,"line":725},6,[668,727,728],{"class":677},"      {\n",[668,730,732],{"class":670,"line":731},7,[668,733,734],{"class":677},"        \"name\": \"Samsung Galaxy A15\",\n",[668,736,738],{"class":670,"line":737},8,[668,739,740],{"class":677},"        \"quantity\": 1,\n",[668,742,744],{"class":670,"line":743},9,[668,745,746],{"class":677},"        \"sku\": \"SM-A155\",\n",[668,748,749],{"class":670,"line":53},[668,750,751],{"class":677},"        \"unit_price\": { \"amount\": \"185000.00\", \"currency\": \"NGN\" },\n",[668,753,754],{"class":670,"line":58},[668,755,756],{"class":677},"        \"warranty\": {\n",[668,758,759],{"class":670,"line":63},[668,760,761],{"class":677},"          \"months\": 12,\n",[668,763,764],{"class":670,"line":68},[668,765,766],{"class":677},"          \"covered_by\": \"manufacturer\",\n",[668,768,769],{"class":670,"line":73},[668,770,771],{"class":677},"          \"provider\": \"Samsung Nigeria\",\n",[668,773,775],{"class":670,"line":774},15,[668,776,777],{"class":677},"          \"terms\": \"Covers faults from manufacture. Not water or screen damage.\"\n",[668,779,781],{"class":670,"line":780},16,[668,782,783],{"class":677},"        }\n",[668,785,787],{"class":670,"line":786},17,[668,788,789],{"class":677},"      },\n",[668,791,793],{"class":670,"line":792},18,[668,794,728],{"class":677},[668,796,798],{"class":670,"line":797},19,[668,799,800],{"class":677},"        \"name\": \"Phone case\",\n",[668,802,803],{"class":670,"line":78},[668,804,740],{"class":677},[668,806,808],{"class":670,"line":807},21,[668,809,810],{"class":677},"        \"unit_price\": { \"amount\": \"5000.00\", \"currency\": \"NGN\" }\n",[668,812,814],{"class":670,"line":813},22,[668,815,816],{"class":677},"      }\n",[668,818,820],{"class":670,"line":819},23,[668,821,822],{"class":677},"    ],\n",[668,824,826],{"class":670,"line":825},24,[668,827,828],{"class":677},"    \"success_url\": \"https:\u002F\u002Fshop.example.com\u002Fthanks\"\n",[668,830,832],{"class":670,"line":831},25,[668,833,834],{"class":677},"  }'\n",[836,837,838,851],"table",{},[839,840,841],"thead",{},[842,843,844,848],"tr",{},[845,846,847],"th",{},"Field",[845,849,850],{},"What it is",[852,853,854,875,892,902],"tbody",{},[842,855,856,866],{},[857,858,859,862,863],"td",{},[636,860,861],{},"months"," or ",[636,864,865],{},"days",[857,867,868,869,871,872,874],{},"How long it lasts: ",[636,870,861],{}," from 1 to 120, or ",[636,873,865],{}," from 1 to 3650. Give one of them.",[842,876,877,882],{},[857,878,879],{},[636,880,881],{},"covered_by",[857,883,884,885,888,889,639],{},"Who honours it: ",[636,886,887],{},"merchant"," (you, the default) or ",[636,890,891],{},"manufacturer",[842,893,894,899],{},[857,895,896],{},[636,897,898],{},"provider",[857,900,901],{},"The manufacturer's name, for a manufacturer's warranty: \"Samsung Nigeria\".",[842,903,904,909],{},[857,905,906],{},[636,907,908],{},"terms",[857,910,911],{},"What it covers, in your words, up to 2,000 characters. The shopper sees this.",[624,913,914,915,918,919,921,922,925,926,928],{},"Then open the checkout with the session's ",[636,916,917],{},"client_secret"," as usual (",[649,920,21],{"href":20},"). ",[649,923,113],{"href":924},"\u002Freference\u002Fcreate-payment-link"," take the same ",[636,927,656],{}," on their lines.",[641,930,932],{"id":931},"_2-what-happens-when-the-order-is-paid","2. What happens when the order is paid",[624,934,935,936,939],{},"When the payment succeeds, Cartirra creates ",[631,937,938],{},"one warranty for each line that has one",":",[941,942,943,947,954,957],"ul",{},[944,945,946],"li",{},"It starts on the day the order was paid and ends on its last covered day. Both are calendar days in Lagos time: a 12-month warranty paid on 27 October 2026 covers up to 26 October 2027.",[944,948,949,950,953],{},"It gets a reference like ",[636,951,952],{},"WRN-20261027-001"," and the order's store.",[944,955,956],{},"A line with a quantity of 2 gets one warranty that covers the line.",[944,958,959,960,962],{},"You get the ",[636,961,598],{}," webhook, and the warranty shows on the order in your dashboard.",[624,964,965,966,969],{},"The shopper keeps the warranty in their Cartirra account, next to the order and its receipt. They're emailed ",[631,967,968],{},"30 days and 7 days"," before it ends, and Cartirra app users also get a notification.",[641,971,973],{"id":972},"_3-add-or-change-a-warranty-after-the-sale","3. Add or change a warranty after the sale",[624,975,976,977,939],{},"Some details are only known later, like a serial number, or you may want to add a warranty to an order that was paid without one. ",[649,978,980],{"href":979},"\u002Freference\u002Fcreate-warranty","Add one to a paid order",[659,982,984],{"className":661,"code":983,"language":663,"meta":664,"style":664},"curl -X POST https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Forders\u002F$ORDER_ID\u002Fwarranties \\\n  -H \"Authorization: Bearer $CARTIRRA_SECRET_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{\n    \"line_index\": 0,\n    \"serial_number\": \"R58W30ABCDE\",\n    \"months\": 12,\n    \"covered_by\": \"manufacturer\",\n    \"provider\": \"Samsung Nigeria\"\n  }'\n",[636,985,986,1007,1019,1027,1033,1038,1043,1048,1053,1058],{"__ignoreMap":664},[668,987,988,990,993,996,999,1002,1005],{"class":670,"line":12},[668,989,674],{"class":673},[668,991,992],{"class":681}," -X",[668,994,995],{"class":677}," POST",[668,997,998],{"class":677}," https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Forders\u002F",[668,1000,1001],{"class":693},"$ORDER_ID",[668,1003,1004],{"class":677},"\u002Fwarranties",[668,1006,682],{"class":681},[668,1008,1009,1011,1013,1015,1017],{"class":670,"line":17},[668,1010,687],{"class":681},[668,1012,690],{"class":677},[668,1014,694],{"class":693},[668,1016,697],{"class":677},[668,1018,682],{"class":681},[668,1020,1021,1023,1025],{"class":670,"line":42},[668,1022,687],{"class":681},[668,1024,706],{"class":677},[668,1026,682],{"class":681},[668,1028,1029,1031],{"class":670,"line":47},[668,1030,713],{"class":681},[668,1032,716],{"class":677},[668,1034,1035],{"class":670,"line":719},[668,1036,1037],{"class":677},"    \"line_index\": 0,\n",[668,1039,1040],{"class":670,"line":725},[668,1041,1042],{"class":677},"    \"serial_number\": \"R58W30ABCDE\",\n",[668,1044,1045],{"class":670,"line":731},[668,1046,1047],{"class":677},"    \"months\": 12,\n",[668,1049,1050],{"class":670,"line":737},[668,1051,1052],{"class":677},"    \"covered_by\": \"manufacturer\",\n",[668,1054,1055],{"class":670,"line":743},[668,1056,1057],{"class":677},"    \"provider\": \"Samsung Nigeria\"\n",[668,1059,1060],{"class":670,"line":53},[668,1061,834],{"class":677},[941,1063,1064,1073],{},[944,1065,1066,1069,1070,639],{},[636,1067,1068],{},"line_index"," is the order line it covers (from 0), and its name is used. Without a line, give ",[636,1071,1072],{},"item_name",[944,1074,1075,1076,862,1078,1080,1081,1084,1085,1088],{},"Give ",[636,1077,861],{},[636,1079,865],{},", or the exact ",[636,1082,1083],{},"ends_on"," date. ",[636,1086,1087],{},"starts_on"," defaults to the day the order was paid.",[624,1090,1091,1092,1096],{},"To change one, ",[649,1093,1095],{"href":1094},"\u002Freference\u002Fupdate-warranty","update it",": the serial number, dates, terms, who covers it, or the item's name.",[659,1098,1100],{"className":661,"code":1099,"language":663,"meta":664,"style":664},"curl -X PATCH https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Fwarranties\u002F$WARRANTY_ID \\\n  -H \"Authorization: Bearer $CARTIRRA_SECRET_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{ \"serial_number\": \"R58W30ABCDE\" }'\n",[636,1101,1102,1120,1132,1140],{"__ignoreMap":664},[668,1103,1104,1106,1108,1111,1114,1117],{"class":670,"line":12},[668,1105,674],{"class":673},[668,1107,992],{"class":681},[668,1109,1110],{"class":677}," PATCH",[668,1112,1113],{"class":677}," https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Fwarranties\u002F",[668,1115,1116],{"class":693},"$WARRANTY_ID ",[668,1118,1119],{"class":681},"\\\n",[668,1121,1122,1124,1126,1128,1130],{"class":670,"line":17},[668,1123,687],{"class":681},[668,1125,690],{"class":677},[668,1127,694],{"class":693},[668,1129,697],{"class":677},[668,1131,682],{"class":681},[668,1133,1134,1136,1138],{"class":670,"line":42},[668,1135,687],{"class":681},[668,1137,706],{"class":677},[668,1139,682],{"class":681},[668,1141,1142,1144],{"class":670,"line":47},[668,1143,713],{"class":681},[668,1145,1146],{"class":677}," '{ \"serial_number\": \"R58W30ABCDE\" }'\n",[624,1148,1149,1150,1154],{},"If the item comes back for a refund, or the warranty was given by mistake, ",[649,1151,1153],{"href":1152},"\u002Freference\u002Fvoid-warranty","void it"," with a reason. The shopper sees it as voided.",[659,1156,1158],{"className":661,"code":1157,"language":663,"meta":664,"style":664},"curl -X POST https:\u002F\u002Fapi.cartirra.com\u002Fv1\u002Fwarranties\u002F$WARRANTY_ID\u002Fvoid \\\n  -H \"Authorization: Bearer $CARTIRRA_SECRET_KEY\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '{ \"reason\": \"Item returned for a refund\" }'\n",[636,1159,1160,1178,1190,1198],{"__ignoreMap":664},[668,1161,1162,1164,1166,1168,1170,1173,1176],{"class":670,"line":12},[668,1163,674],{"class":673},[668,1165,992],{"class":681},[668,1167,995],{"class":677},[668,1169,1113],{"class":677},[668,1171,1172],{"class":693},"$WARRANTY_ID",[668,1174,1175],{"class":677},"\u002Fvoid",[668,1177,682],{"class":681},[668,1179,1180,1182,1184,1186,1188],{"class":670,"line":17},[668,1181,687],{"class":681},[668,1183,690],{"class":677},[668,1185,694],{"class":693},[668,1187,697],{"class":677},[668,1189,682],{"class":681},[668,1191,1192,1194,1196],{"class":670,"line":42},[668,1193,687],{"class":681},[668,1195,706],{"class":677},[668,1197,682],{"class":681},[668,1199,1200,1202],{"class":670,"line":47},[668,1201,713],{"class":681},[668,1203,1204],{"class":677}," '{ \"reason\": \"Item returned for a refund\" }'\n",[641,1206,1208],{"id":1207},"_4-find-warranties","4. Find warranties",[624,1210,1211,1217],{},[649,1212,1214],{"href":1213},"\u002Freference\u002Flist-warranties",[636,1215,1216],{},"GET \u002Fv1\u002Fwarranties"," lists them, newest first, and you can filter by:",[941,1219,1220,1241,1253],{},[944,1221,1222,1225,1226,1229,1230,1233,1234,862,1237,1240],{},[636,1223,1224],{},"state",": ",[636,1227,1228],{},"active"," (still covering, including those ending soon), ",[636,1231,1232],{},"ending_soon"," (30 days or fewer left), ",[636,1235,1236],{},"expired",[636,1238,1239],{},"voided",";",[944,1242,1243,1246,1247,862,1250,1240],{},[636,1244,1245],{},"order_id",", ",[636,1248,1249],{},"customer_id",[636,1251,1252],{},"store_id",[944,1254,1255,1258],{},[636,1256,1257],{},"q",": searches the item name, serial number and reference.",[624,1260,1261,1267],{},[649,1262,1264],{"href":1263},"\u002Freference\u002Flist-order-warranties",[636,1265,1266],{},"GET \u002Fv1\u002Forders\u002F{id}\u002Fwarranties"," lists one order's warranties.",[641,1269,77],{"id":1270},"webhooks",[836,1272,1273,1283],{},[839,1274,1275],{},[842,1276,1277,1280],{},[845,1278,1279],{},"Event",[845,1281,1282],{},"Sent when",[852,1284,1285,1297,1309],{},[842,1286,1287,1294],{},[857,1288,1289],{},[649,1290,1292],{"href":1291},"\u002Freference\u002Fwebhooks\u002Fwarranty-created",[636,1293,598],{},[857,1295,1296],{},"A warranty starts: an order with one is paid, or you add one",[842,1298,1299,1306],{},[857,1300,1301],{},[649,1302,1304],{"href":1303},"\u002Freference\u002Fwebhooks\u002Fwarranty-updated",[636,1305,601],{},[857,1307,1308],{},"You change its serial number, dates, terms or cover",[842,1310,1311,1318],{},[857,1312,1313],{},[649,1314,1316],{"href":1315},"\u002Freference\u002Fwebhooks\u002Fwarranty-voided",[636,1317,604],{},[857,1319,1320],{},"You void it",[624,1322,1323,1324,1326,1327,862,1330,639],{},"A warranty expiring sends no webhook. Read ",[636,1325,1083],{},", or list with ",[636,1328,1329],{},"state=ending_soon",[636,1331,1332],{},"state=expired",[641,1334,1336],{"id":1335},"permissions","Permissions",[624,1338,1339,1340,1343,1344,1347],{},"Secret keys can read and manage warranties. In the dashboard, team members need ",[636,1341,1342],{},"warranties:read"," to see them and ",[636,1345,1346],{},"warranties:write"," to add, change or void them.",[1349,1350,1351],"style",{},"html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sZZnC, html code.shiki .sZZnC{--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .sj4cs, html code.shiki .sj4cs{--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sVt8B, html code.shiki .sVt8B{--shiki-default:#24292E;--shiki-dark:#E1E4E8}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":664,"searchDepth":17,"depth":42,"links":1353},[1354,1355,1356,1357,1358,1359],{"id":643,"depth":17,"text":644},{"id":931,"depth":17,"text":932},{"id":972,"depth":17,"text":973},{"id":1207,"depth":17,"text":1208},{"id":1270,"depth":17,"text":77},{"id":1335,"depth":17,"text":1336},"md",{},true,{"title":36,"description":38},"guides\u002Fwarranties","YyvMFyX_Vpo-fTRqRh9m8NvpphxQIfmggqBsLFgEaoQ",[1367,1369],{"title":31,"path":30,"stem":1368,"children":-1},"guides\u002Fpay-at-table",{"title":41,"path":40,"stem":1370,"children":-1},"guides\u002Fauthentication",1795864569970]