iRetail PRO store node 1.0.0-m1
266 операций
← Вся документация · Источник: контракты, openapi/store-v1.yaml на коммите 8000474.
Справочники на английском — на языке контрактов, из которых они созданы.
REST API of the node in the store role. Conventions: spec/API.md; permissions: spec/RBAC.md (each operation names its permission in x-permission); stock rules: spec/STOCK.md; amounts: spec/RECEIPT_MATH.md. Every request from an app carries IRetail-App (components/parameters/IRetailApp, on every path an app calls), and the node may refuse an app 426 app_update_required by it except on an operation marked x-app-update-exempt; a property added to a schema after 1.0 carries x-since (spec/RELEASES.md, Apps and the gateway).
health 1 операция
- GET
/healthzLiveness and role.
receipts 5 операций
- POST
/v1/receipts/calculateCompute receipt amounts without storing anything (spec/RECEIPT_MATH.md). - GET
/v1/receiptsReceipts. - POST
/v1/receiptsSale (receipt.sell), refund (receipt.refund, receipt.refund.any_shift) or void (receipt.void). - GET
/v1/receipts/{id}One receipt. - POST
/v1/receipts/{id}/sendSend a receipt to the customer by e-mail or SMS (spec/API.md, "Electronic receipts").
auth 2 операции
- POST
/v1/auth/loginLog an employee in on this device; the device token authorizes the call. - POST
/v1/auth/logoutRevoke the presented employee token.
me 2 операции
- GET
/v1/meThe caller and its effective permissions in its context. - PUT
/v1/me/pinSet a new PIN for the signed-in employee, giving the current one (spec/RBAC.md, PINs).
approvals 1 операция
- POST
/v1/approvalsA senior employee's one-time approval for a permission in this context (spec/RBAC.md).
store 2 операции
- GET
/v1/storeThis store's settings. - PATCH
/v1/storeChange store settings.
tax-rates 9 операций
- GET
/v1/tax-ratesTax rates of this store. - PUT
/v1/tax-rates/{code}Create or change a tax rate. - DELETE
/v1/tax-rates/{code}Delete a tax rate no item or service charge uses (409 conflict otherwise). - GET
/v1/tax-providerWhere this store's tax rates come from, and how the last sync went (spec/TAX.md). - PUT
/v1/tax-providerSet the tax service that fills this store's rates; the key is only named. - POST
/v1/tax-provider/syncAsk the tax service for the rates now; answers the status after the attempt. - GET
/v1/depositsContainer deposits of this store (spec/TAX.md). - PUT
/v1/deposits/{code}Create or change a container deposit. - DELETE
/v1/deposits/{code}Delete a deposit no item names.
devices 4 операции
- GET
/v1/devicesRegistered devices (workplaces). - POST
/v1/devicesRegister a device; the token is shown once. - PUT
/v1/devices/{id}/fiscalSet a register's fiscal back ends (spec/FISCAL.md). - DELETE
/v1/devices/{id}Revoke a device and its token.
network 4 операции
- GET
/v1/devices/me/wireguardThis device's private-network profile (spec/NETWORK.md). - PUT
/v1/devices/me/wireguardRegister this device's WireGuard public key; the node assigns its address and answers its profile. - DELETE
/v1/devices/me/wireguardRemove this device's peer. - GET
/v1/networkThe private network as this store sees it - on or off, its profile, the tunnel, its devices' peers (spec/NETWORK.md).
integrations 3 операции
- GET
/v1/integrationsIntegration tokens. - POST
/v1/integrationsIssue an integration token; shown once. - DELETE
/v1/integrations/{id}Revoke an integration token.
roles 2 операции
- GET
/v1/rolesRoles of the organization. - PUT
/v1/roles/{code}Create or change a custom role; built-in roles are read-only.
employees 6 операций
- GET
/v1/employeesEmployees. - POST
/v1/employeesCreate an employee. - GET
/v1/employees/{id}One employee. - PATCH
/v1/employees/{id}Change an employee. - POST
/v1/employees/{id}/assignmentsAssign a role in a scope (no wider than one's own). - DELETE
/v1/employees/{id}/assignments/{assignment_id}Remove an assignment.
groups 2 операции
- GET
/v1/groupsItem groups. - POST
/v1/groupsCreate an item group.
tags 3 операции
- GET
/v1/tagsThe catalog's tags (spec/SEARCH.md). - POST
/v1/tagsCreate a tag. - PATCH
/v1/tags/{id}Rename a tag; the items carrying it are embedded again.
change-requests 2 операции
- GET
/v1/change-requestsThis store's requests to its hub for hub-owned changes (spec/SYNC.md), newest first. - POST
/v1/change-requestsAsk the hub for a new item or a price now; the proposal is usable in the store while pending (item.edit, or price.edit for a price).
promotions 4 операции
- GET
/v1/promotionsThe store's promotions, inactive ones included (spec/PROMOTIONS.md). - POST
/v1/promotionsCreate a promotion. - PATCH
/v1/promotions/{id}Change a promotion. - DELETE
/v1/promotions/{id}Delete a promotion.
items 11 операций
- GET
/v1/itemsItems with this store's prices. - POST
/v1/itemsCreate an item. - GET
/v1/items/lookupResolve a scanned or typed code: barcode, pack barcode, variable-measure barcode, PLU or SKU. - POST
/v1/items/lookupThe same lookup with the code in the body. - GET
/v1/items/{id}One item. - PATCH
/v1/items/{id}Change an item. - POST
/v1/items/{id}/variantsMake the variants a parent lacks (spec/VARIANTS.md). - PUT
/v1/items/{id}/priceSet this store's price of an item. - POST
/v1/item-photosKeep a JPEG or WebP photo of at most 512 KB for an item to name, its EXIF and XMP removed (spec/PUBLIC_API.md, The storefront); kept by the catalog's owner, 409 owned_by_hub at a store of a chain. - GET
/v1/item-photos/{id}An item photo's bytes with its ETag; 304 for a matching If-None-Match; photos do not cross to stores of a chain (404 there). - DELETE
/v1/item-photos/{id}Delete a photo no item names (409 photo_in_use otherwise).
stock 4 операции
- GET
/v1/stockOn hand, held and available by item. - GET
/v1/stock/{item_id}Stock of one item with its batches. - GET
/v1/serials/{serial}The item serials that match a serial number, with their history (spec/VARIANTS.md). - GET
/v1/stock/in-transitLines of transfers from or to this store that are in transit.
holds 4 операции
- GET
/v1/holdsActive hard holds. - POST
/v1/holdsPlace a hard hold (spec/STOCK.md). - POST
/v1/holds/{id}/extendExtend a hold by the store's TTL. - DELETE
/v1/holds/{id}Release a hold.
documents 14 операций
- GET
/v1/documentsStock documents. - POST
/v1/documentsCreate a draft document (inventory needs inventory.count or document.edit). - GET
/v1/documents/{id}One document. - PATCH
/v1/documents/{id}Change a draft. - POST
/v1/documents/{id}/postPost a draft: stock changes now. - POST
/v1/documents/{id}/cancelCancel a draft. - POST
/v1/documents/{id}/countsAdd one device's counts to a draft inventory document (spec/STOCK.md, Counts from several devices). - GET
/v1/transfersThe store's transfers, both documents (spec/STOCK.md, Transfers). - GET
/v1/transfers/{id}One transfer with both documents. - POST
/v1/transfers/{id}/receivingThe draft transfer_in of an incoming transfer, prefilled with what was shipped; the existing one when there is one. - POST
/v1/documents/{id}/closeClose a sent purchase order: what is still due is given up. - GET
/v1/suppliersSuppliers. - POST
/v1/suppliersAdd a supplier. - PATCH
/v1/suppliers/{id}Change a supplier.
shifts 6 операций
- GET
/v1/shiftsShifts. - POST
/v1/shiftsOpen a shift on the caller's workplace. - GET
/v1/shifts/{id}One shift. - POST
/v1/shifts/{id}/cash-operationsDeposit (shift.cash.deposit), payout (shift.cash.payout, limited) or pickup (shift.cash.pickup). - GET
/v1/shifts/{id}/reportX totals of a shift so far, of the whole shift or one cashier (spec/API.md, Shared registers). - POST
/v1/shifts/{id}/closeClose a shift with Z totals and the counted cash.
kitchen 4 операции
- GET
/v1/kitchen/ticketsA station's kitchen tickets, oldest first (spec/FOOD_SERVICE.md, "Kitchen display"). - POST
/v1/kitchen/tickets/{id}/startStart a new ticket. - POST
/v1/kitchen/tickets/{id}/readyBump a new or started ticket as ready. - POST
/v1/kitchen/tickets/{id}/recallBring a ticket bumped in the last 15 minutes back as started.
pharmacy 2 операции
- GET
/v1/pse/logThe pseudoephedrine logbook, newest first (spec/PHARMACY.md). - GET
/v1/pse/log/exportThe pseudoephedrine logbook of a period as CSV.
events 2 операции
- GET
/v1/eventsEvents after a sequence number (spec/API.md). - GET
/v1/events/streamWebSocket upgrade; each message is one event (envelope).
license 2 операции
- GET
/v1/licenseThe installed license and its status. - PUT
/v1/licenseInstall a license key (spec/LICENSE.md).
audit 3 операции
- GET
/v1/auditThe audit log. - GET
/v1/audit/exportThe audit log as JSON lines, with its hashes (spec/AUDIT.md). - GET
/v1/audit/verifyWalk the audit chain and say where it breaks (spec/AUDIT.md).
reports 12 операций
- GET
/v1/reports/salesSales by day, employee, item, group or tender (spec/REPORTS.md). - GET
/v1/reports/taxTaxable base and tax by code, with SNAP, nontaxable sales and deposits (spec/REPORTS.md, "Tax"). - GET
/v1/reports/stockStock on hand with value at cost (spec/REPORTS.md). - GET
/v1/reports/movementsStock movements in a period (spec/REPORTS.md). - GET
/v1/bonus-rulesEmployee bonus rules (spec/REPORTS.md, Employee bonuses). - POST
/v1/bonus-rulesAdd a bonus rule. - PATCH
/v1/bonus-rules/{id}Change a bonus rule; recorded lines keep their bonus. - DELETE
/v1/bonus-rules/{id}Delete a bonus rule. - GET
/v1/reports/bonusesEmployee bonuses over [from, to) (spec/REPORTS.md). - GET
/v1/reports/partnersPartners' revenue, margin and commission over [from, to) (spec/REPORTS.md). - GET
/v1/reports/restaurantChecks closed in [from, to) with covers, revenue, averages, table time and tips (spec/REPORTS.md, Restaurant). - GET
/v1/reports/service-chargesService charges in [from, to) without their tax, the staff's part and the house's, by day, employee or charge; the payroll basis apart from tips (spec/REPORTS.md, Service charges).
pricing 6 операций
- POST
/v1/pricing/proposalsPrices proposed from the last receiving cost by a markup rule (spec/PRICING.md). Writes nothing. - GET
/v1/expiry-rulesExpiry rules (spec/PRICING.md, Expiry rules). - POST
/v1/expiry-rulesAdd an expiry rule. - PATCH
/v1/expiry-rules/{id}Change an expiry rule. - DELETE
/v1/expiry-rules/{id}Delete an expiry rule. - POST
/v1/expiry-rules/runRun today's expiry rules if they have not run; answers the day's documents either way.
imports 10 операций
- POST
/v1/importsRead a CSV, XLSX or Google Sheet into an import session (spec/IMPORT.md). - GET
/v1/imports/{id}An import session. - POST
/v1/imports/{id}/previewWhat each row would do under a mapping; writes nothing. - POST
/v1/imports/{id}/applyWrite the create and update rows in one transaction; error rows are skipped. - GET
/v1/exports/itemsEvery item with the import's columns, as CSV or XLSX (spec/IMPORT.md, Export). - GET
/v1/exports/stockThe stock report as CSV or XLSX. - GET
/v1/exports/salesThe sales report as CSV or XLSX. - GET
/v1/exports/taxThe tax report as CSV or XLSX. - GET
/v1/exports/service-chargesThe service charge report as CSV or XLSX. - GET
/v1/exports/restaurantThe restaurant report as CSV or XLSX.
proposals 4 операции
- GET
/v1/proposalsChanges agents proposed that the caller asked for or may approve, newest first (spec/MCP.md). - GET
/v1/proposals/{id}One proposal. - POST
/v1/proposals/{id}/approveCarry the change out as the approver; a refusal of the domain leaves it failed with the error. - POST
/v1/proposals/{id}/refuseRefuse a proposal with a reason.
assistant 8 операций
- GET
/v1/assistant/settingsThe assistant's provider, model, data policy and prices (spec/ASSISTANT.md); never the key. - PUT
/v1/assistant/settingsSet the assistant up. - GET
/v1/assistant/conversationsThe caller's conversations, newest first. - POST
/v1/assistant/conversationsStart a conversation. - GET
/v1/assistant/conversations/{id}One of the caller's conversations with its messages. - DELETE
/v1/assistant/conversations/{id}Delete one of the caller's conversations. - POST
/v1/assistant/conversations/{id}/messagesSay something; the turn runs on the node and the conversation is read again until it is idle or failed. - GET
/v1/assistant/callsThe log of requests to the provider, newest first; never a prompt, a key or a result.
search 8 операций
- GET
/v1/search/itemsSearch the catalog by meaning, exact matches first (spec/SEARCH.md, Searching); the license module search. - GET
/v1/search/suggestionsTags and groups the node suggests for items, newest first (spec/SEARCH.md, Suggestions). - POST
/v1/search/suggestions/{id}/acceptGive the item the tag or the group, as an edit of the item by the caller. - POST
/v1/search/suggestions/{id}/dismissDo not suggest it again for the item. - GET
/v1/search/settingsThe embedding provider and the suggestions' settings (spec/SEARCH.md); never the key. - PUT
/v1/search/settingsSet search up; a change of the model starts a new index. - GET
/v1/search/indexThe active index and the one building, with their progress. - POST
/v1/search/index/rebuildStart a new index with the settings' model; the active one answers until it is ready.
stores 1 операция
- GET
/v1/store-directoryThe chain's stores, each by id, code and name only (spec/SYNC.md); empty in a store with no hub.
catalog 4 операции
- GET
/v1/recipesRecipes (spec/STOCK.md, Recipes and production). - POST
/v1/recipesAdd a recipe. - PATCH
/v1/recipes/{id}Change a recipe. - GET
/v1/items/{id}/price-splitHow a quantity of the item splits into lines by batch price (spec/PRICING.md, Batch prices); nothing is held.
loyalty 31 операция
- GET
/v1/loyalty/programsLoyalty programs (spec/LOYALTY.md, Programs). - POST
/v1/loyalty/programsAdd a loyalty program. - PATCH
/v1/loyalty/programs/{id}Change a loyalty program; its kind stays. - GET
/v1/customersCustomers, masked; by a name's prefix or a phone's last four digits. - POST
/v1/customersEnroll a customer (at the hub in a chain, online only). - POST
/v1/customers/lookupThe customer a card number or an E.164 phone finds, exactly; masked. - GET
/v1/customers/{id}One customer, masked. - PATCH
/v1/customers/{id}Change a customer's record or cards. - DELETE
/v1/customers/{id}Erase the customer's personal data; the ledgers' totals stay (spec/LOYALTY.md, Customers). - GET
/v1/customers/{id}/balancesThe customer's points and stamps at the balance owner. - GET
/v1/customers/{id}/ledgerThe customer's ledger entries, newest first. - POST
/v1/customers/{id}/adjustmentsCorrect a customer's points or stamps with a reason; audited. - GET
/v1/loyalty/holdsBalance holds by status (orphaned ones for a person to look at). - POST
/v1/loyalty/holdsReserve points, stamps, a gift card amount or a voucher use at the balance owner for 15 minutes. - DELETE
/v1/loyalty/holds/{id}Release a held hold (a cleared sale) with receipt.sell, or an orphaned one with loyalty.manage alone (spec/LOYALTY.md, Expiry and release). - GET
/v1/vouchersVouchers and coupons. - POST
/v1/vouchersAdd a voucher or coupon. - POST
/v1/vouchers/generateMake vouchers with codes the node generates. - PATCH
/v1/vouchers/{id}Change a voucher; its code and rule stay. - POST
/v1/vouchers/lookupA code's voucher and whether it can be used now. - GET
/v1/gift-cardsGift cards, masked. - POST
/v1/gift-cards/balanceA card's balance; the number goes in the body, never in a URL. - GET
/v1/gift-cards/{id}One gift card, masked, with its balance. - PATCH
/v1/gift-cards/{id}Block or unblock a gift card; audited. - POST
/v1/gift-cards/issueMake cards with random 16-digit numbers; the numbers and PINs are shown in this answer only. - POST
/v1/gift-cards/importImport cards a supplier printed by number; each number is hashed and dropped. - PUT
/v1/gift-cards/{id}/pinSet or remove a card's PIN, kept as an Argon2id hash; audited, never the PIN. - GET
/v1/gift-cards/{id}/ledgerA gift card's ledger entries, newest first. - GET
/v1/partnersPartners and their codes. - POST
/v1/partnersAdd a partner. - PATCH
/v1/partners/{id}Change a partner.
floor 8 операций
- GET
/v1/floorThe floor's areas and tables with their live state (spec/RESTAURANT.md, The floor), with check.use or floor.manage; QR tokens only with floor.manage. - POST
/v1/areasAdd an area (a room) to the floor. - PATCH
/v1/areas/{id}Rename or reorder an area. - DELETE
/v1/areas/{id}Delete an area with no tables (409 area_not_empty otherwise). - POST
/v1/tablesDraw a table on an area's grid; it gets its QR token. - PATCH
/v1/tables/{id}Move, resize, rotate, rename a table or change its seats or area. - DELETE
/v1/tables/{id}Delete a table with no open or billed check (409 table_in_use otherwise). - POST
/v1/tables/{id}/tokenDraw a new QR token for a table; the old one is retired and answers 404 to guests from now on.
checks 22 операции
- GET
/v1/checksChecks, oldest first (spec/RESTAURANT.md, Checks); by default the open and billed ones. - POST
/v1/checksOpen a check on a table, or a named tab, with its covers and optionally its first lines; the caller is its waiter. - GET
/v1/checks/{id}One check with its lines and totals. - PATCH
/v1/checks/{id}Change a check's covers, a tab's name, held courses, customer, partner code or percent receipt discounts. - POST
/v1/checks/{id}/linesAdd lines, unsent, holding stock for stocked items (spec/RESTAURANT.md, Stock on a check). - PATCH
/v1/checks/{id}/lines/{line_no}Change a line; quantity, options, course and price only while it is unsent (409 line_sent). - DELETE
/v1/checks/{id}/lines/{line_no}Delete an unsent line without a trace, releasing its hold (a sent line is voided instead). - POST
/v1/checks/{id}/lines/{line_no}/voidVoid a sent line with a reason; its station gets a cancel (spec/RESTAURANT.md, Courses and the kitchen). - POST
/v1/checks/{id}/sendSend the unsent lines of every course that is not held to the kitchen. - POST
/v1/checks/{id}/fireSend a course's unsent lines, held or not, and stop holding it. - POST
/v1/checks/{id}/renewRenew the check's holds for the store's check_hold_minutes and place lapsed ones again; raises no version. - POST
/v1/checks/{id}/billMake the check billed and answer its pre-bill, which is not a fiscal document (spec/RESTAURANT.md, The pre-bill). - POST
/v1/checks/{id}/reopenMake a billed check open again. - POST
/v1/checks/{id}/cancelCancel a check with nothing to pay; unsent lines are deleted and holds released (409 check_not_empty otherwise). - POST
/v1/checks/{id}/moveMove a check to another table, or make it a tab (spec/RESTAURANT.md, Moving). - POST
/v1/checks/{id}/mergeMerge another check into this one, its seats moved up past this check's guests; the other is canceled. - POST
/v1/checks/{id}/move-linesMove chosen lines to another check, with their holds; answers the check they left. - POST
/v1/checks/{id}/transferPass a check to another waiter. - PUT
/v1/checks/{id}/service-charges/{charge_id}Add a store's service charge to a check by hand, remove it with a reason (service_charge.remove too, or a senior's approval), or hand it back to the store's rules (spec/RESTAURANT.md, Service charges). - POST
/v1/checks/{id}/splitThe receipts a split would make, each figured by the receipt math, with their parts; changes nothing. - GET
/v1/check-conflictsOffline receipts of checks that did not apply, for a person to settle (spec/RESTAURANT.md, Offline). - POST
/v1/check-conflicts/{id}/resolveApply an offline receipt to its check after all, or dismiss the conflict.409 check_conflict_resolvedfor one already resolved, before its version is compared.
guest-orders 3 операции
- GET
/v1/guest-ordersGuests' orders, pending first, oldest first within each state (spec/RESTAURANT.md, The guest listener). - POST
/v1/guest-orders/{id}/confirmAdd a pending guest order's lines to a check of its table, or to a new check the caller opens. - POST
/v1/guest-orders/{id}/refuseRefuse a pending guest order with a reason the guest sees.
updates 13 операций
- GET
/v1/updateThis store's update (spec/RELEASES.md, The store's update) — the running and previous release, the target, its state, the backup's and rehearsal's outcomes, background tasks, the hub's refusal if the exchange is refused, and its apps' versions and offers. - PUT
/v1/updateA store with no hub sets its own update target (spec/RELEASES.md, A store with no hub), which its updater applies. 409 owned_by_hub in a store of a chain; 400 bad_version, 400 bad_request (action, window); 404 for a version not held; 409 release_not_verified; 422 release_refused (downgrade). - GET
/v1/app-updateWhat an app or the gateway should run, by the release the node runs, one device of the store first (spec/RELEASES.md, The apps); the installer comes from this node. - POST
/v1/app-update/reportAn app or the gateway reports where its update stands (spec/RELEASES.md, Reporting); kept as the device's Device.app. - POST
/v1/app-update/clearClear the store's hold of a release for an app and platform after its first device failed it (spec/RELEASES.md, One device first); the next device to ask becomes the first again. 404 when nothing is held. - GET
/v1/releasesThe releases a store with no hub holds, the latest version first (spec/RELEASES.md, A store with no hub); 409 owned_by_hub in a store of a chain. - GET
/v1/releases/availableWhat the source (IRETAIL_RELEASES_URL) offers as its latest release, and whether this store holds it. 409 owned_by_hub in a store of a chain, 409 release_source_missing with downloading off, 503 release_source_unreachable. - POST
/v1/releases/downloadA store with no hub downloads a release from its source, as the hub does; the manifest is verified before answering (422 release_refused), the artifacts it keeps (roles with store) follow. 409 owned_by_hub in a store of a chain, 409 release_storage_missing without IRETAIL_RELEASES_DIR. - POST
/v1/releases/importA store with no hub imports a release bundle (the raw body, a POSIX tar), verified as it streams, as the hub does; it keeps the artifacts whose roles hold store. 409 owned_by_hub in a store of a chain. - GET
/v1/releases/{version}One release a store with no hub holds, with its signed manifest; 409 owned_by_hub in a store of a chain. - DELETE
/v1/releases/{version}Remove a release and its files; 409 release_in_use while the store runs it, ran it before or its own target names it; 409 owned_by_hub in a store of a chain. - GET
/v1/releases/{version}/manifestThe signed manifest of a release this node holds (the one it runs, ran before or is given; at a store with no hub, any it holds verified); for the updater (its token), devices and employees. The caller verifies it with its own embedded keys. - GET
/v1/releases/{version}/artifacts/{name}A file of a release this node holds, verified when it arrived;Rangeresumes a broken download. The caller checks its size and SHA-256 against the manifest.
updater 2 операции
- GET
/v1/updater/targetThe updater reads its node's target (spec/RELEASES.md, The updater's API);404when the node has no updater token. - POST
/v1/updater/reportThe updater reports its state for the target's record version; a report for an older record version is ignored.
brand 5 операций
- GET
/v1/brandThe effective brand of the caller's store: the brand overlaid with the store's banner, or the default (spec/BRANDS.md, What the apps get); 304 for a matching If-None-Match. - PUT
/v1/brandSet the organization's brand: checked as spec/BRANDS.md says (422 invalid_brand, 422 brand_contrast); 403 module_disabled without white_label; 409 owned_by_hub at a store of a chain. - GET
/v1/brand/settingsThe organization's brand as kept, served whether or not the key holds white_label; 404 when there is none. - POST
/v1/brand/imagesUpload a PNG of at most 128 KiB for a brand or a banner to name; only its header is read (422 invalid_brand, reason not_png). Its id is the SHA-256 of its bytes, so uploading the same bytes again answers the same image. - GET
/v1/brand/images/{id}An image of the brand or a banner, its bytes never changing; 304 for a matching If-None-Match.
customer-app 4 операции
- GET
/v1/customer-appThe customer app's setting (spec/PUBLIC_API.md, The listener): at the hub, or a store with no hub; 409 owned_by_hub at a store of a chain. - PUT
/v1/customer-appSet the customer app at the setting's version; 422 invalid_customer_app with field and reason, checked in spec/PUBLIC_API.md's order. Audited (customer_app.set). - POST
/v1/customer-app/card-keyMake a new card key; every card token made with the old one stops being taken at once. Audited (customer_app.card_key_renewed); the key itself is never answered, shown or logged. - POST
/v1/customer-app/pushesSend a promotion push to the customers who take promotions, allow marketing and had none today; 422 pushes_unavailable when no push account is set. Audited (customer_app.push_sent); no agent tool reaches it.
preorders 6 операций
- GET
/v1/preordersThe store's preorders by their effective state (spec/PREORDERS.md), soonest window first; at the hub every store's, store_id filtering. - GET
/v1/preorders/{id}One preorder with its lines, window, payment and effective state. - POST
/v1/preorders/{id}/readyMark an accepted preorder picked; the customer gets preorder_ready (409 preorder_state otherwise). - POST
/v1/preorders/{id}/cancelCancel a preorder with a reason: its holds are given back, an authorization released, and the customer gets preorder_canceled. At the hub the cancel crosses to the store; 409 preorder_state for a final one. - POST
/v1/preorders/{id}/payment/captureCapture a preorder's online payment for the receipt that hands it over (spec/PAYMENTS_ONLINE.md, Capture): served by the owner, which a store of a chain forwards it to; the store's node calls it while recording the receipt, the register never. 409 capture_failed, 422 payment_refused (provider_code). - POST
/v1/preorders/{id}/payment/refundRefund part of a captured online payment for a refund or void receipt (spec/PAYMENTS_ONLINE.md, Refunds); served by the owner, forwarded by a store of a chain. 422 refund_exceeds_payment (remaining), payment_refused.