/api/public/v1/healthLiveness probe plus database connectivity check and API version.
Agent guidance: Call once at startup to confirm the API and dataset are reachable.
Try /api/public/v1/healthBookly ยท demo bookstore
A fully API-native order, shipping, returns and refunds system for building a customer support agent. No authentication, open CORS, 34 documented endpoints.
{ "data": ..., "meta": { "request_id" } }; errors use an RFC 9457-style envelope.BK-#####; customers accept UUID or email.limit (max 100) and offset.Health and discovery.
/api/public/v1/healthLiveness probe plus database connectivity check and API version.
Agent guidance: Call once at startup to confirm the API and dataset are reachable.
Try /api/public/v1/health/api/public/v1/metaRow counts, live sample identifiers (order numbers, emails, RMAs, tracking numbers), every enum value and the business-rule constants. This is the recommended bootstrap call for an agent.
Agent guidance: Fetch first so you can use real identifiers in later calls instead of guessing.
Try /api/public/v1/metaOrder lookup, cancellation and line items.
/api/public/v1/ordersPaginated order list with filters. Use `email` when a customer contacts support without an order number.
Agent guidance: Primary lookup when the customer gives an email address rather than an order number.
Try /api/public/v1/orders?limit=3&status=shipped/api/public/v1/orders/{id}Full order with customer, line items, shipments, returns, refunds and transactions embedded.
Agent guidance: The single richest call for answering 'where is my order?'.
Try /api/public/v1/orders/BK-10042/api/public/v1/orders/{id}/itemsLine items with the joined book record (format matters for return eligibility).
Agent guidance: Use the returned order_item_id values when creating a partial return.
Try /api/public/v1/orders/BK-10042/items/api/public/v1/orders/{id}/cancelCancels an order and voids the authorization. Only allowed while the status is processing or backordered.
Agent guidance: Use for 'cancel my order'. If it returns 409, offer a return instead.
See request body in the OpenAPI specShipments, tracking events and reshipments.
/api/public/v1/orders/{id}/shipmentsAll shipments for the order, each with its full tracking event history.
Agent guidance: Answer delivery-timing questions and detect stalled tracking.
Try /api/public/v1/orders/BK-10042/shipments/api/public/v1/orders/{id}/reshipGenerates a new shipment and tracking number. Allowed when the order is lost_in_transit or shipped.
Agent guidance: Use for lost-in-transit packages after confirming tracking is stalled.
See request body in the OpenAPI spec/api/public/v1/shipments/{tracking}Fetch a shipment by tracking number or UUID, with its events and parent order.
Agent guidance: Direct tracking lookup when the customer pastes a tracking number.
Try /api/public/v1/shipments/1Z999AA10123456784/api/public/v1/shipments/{tracking}/eventsChronological scan events for a shipment.
Agent guidance: Detect a stalled package: no new scan for 7+ days means offer a reship.
Try /api/public/v1/shipments/1Z999AA10123456784/eventsEligibility, RMA creation and lifecycle.
/api/public/v1/orders/{id}/returns/eligibilityDeterministic eligibility check. Standard window is 30 days from delivery; damaged or wrong-item claims get 90 days and waive the $4.99 label fee. Ebooks are non-returnable.
Agent guidance: Always call this before creating a return so you can explain the outcome to the customer.
See request body in the OpenAPI spec/api/public/v1/returnsPaginated returns with their items and parent order.
Agent guidance: Check whether a return already exists before creating a duplicate.
Try /api/public/v1/returns?limit=3/api/public/v1/returnsCreates an RMA with a prepaid label and computes the expected refund. Rejects with 409 when the order is not eligible unless `override_eligibility` is true.
Agent guidance: Call after eligibility passes. `items` is optional โ omit it to return every line on the order, or match lines by order_item_id, isbn or title. Set initiate_refund to open the refund in the same call.
See request body in the OpenAPI spec/api/public/v1/returns/{rma}Fetch a return by RMA number (RMA-12345) or UUID.
Agent guidance: Answer 'what is the status of my return?'.
Try /api/public/v1/returns/RMA-12345/api/public/v1/returns/{rma}/receiveMoves the return to `received`, optionally issuing the refund immediately.
Agent guidance: Warehouse-side action; set auto_refund to close the loop in one call.
See request body in the OpenAPI spec/api/public/v1/returns/{rma}/cancelCancels an open RMA. Fails with 409 once the return is refunded.
Agent guidance: Use when the customer decides to keep the item.
See request body in the OpenAPI specRefunds, store credit and the money ledger.
/api/public/v1/refundsPaginated refunds with their parent order.
Agent guidance: Confirm whether money already went back before promising a new refund.
Try /api/public/v1/refunds?limit=3/api/public/v1/refundsIssues a full or partial refund, records the matching ledger transaction, credits store credit when requested and flips the order to `refunded` once fully covered. Over-refunding is rejected.
Agent guidance: Use for goodwill refunds and post-return settlements.
See request body in the OpenAPI spec/api/public/v1/refunds/{id}Fetch a refund by refund number (RF-12345) or UUID.
Agent guidance: Give the customer the exact refund amount and timing.
Try /api/public/v1/refunds/RF-12345/api/public/v1/refunds/{id}Moves a refund to any status. Settling (`succeeded`) writes the ledger transaction, applies store credit and flips the order to refunded once fully covered; cancelling or failing a settled refund writes a reversal. Every change appends to the refund timeline (`events`).
Agent guidance: Use to release a `pending_return` refund early for a loyal customer, or to cancel a refund the customer no longer wants.
See request body in the OpenAPI spec/api/public/v1/transactionsImmutable money ledger: charges, refunds and voids.
Agent guidance: Reconcile what the customer was actually charged.
Try /api/public/v1/transactions?limit=3Customer identity and order history.
/api/public/v1/customersSearch customers by email, fuzzy name/email query or loyalty tier.
Agent guidance: Identity resolution before touching order data.
Try /api/public/v1/customers?limit=3/api/public/v1/customers/{id}Fetch by UUID or email (URL-encoded), including saved addresses and store credit.
Agent guidance: Check store credit balance before offering it as a refund method.
Try /api/public/v1/customers/ava.brooks@example.com/api/public/v1/customers/{id}/ordersOrder history for a customer, newest first. Accepts UUID or email.
Agent guidance: Use when the customer says 'my last order' without a number.
Try /api/public/v1/customers/ava.brooks@example.com/ordersBook catalog search.
/api/public/v1/booksSearch books by title, author or ISBN with category, format and stock filters.
Agent guidance: Recommend replacements or confirm stock before promising a reship.
Try /api/public/v1/books?q=the&limit=3/api/public/v1/books/{id}Fetch a book by UUID or ISBN-13.
Agent guidance: Confirm format โ ebooks cannot be returned.
Try /api/public/v1/books/9780000000017Policies and FAQs for grounded answers.
/api/public/v1/policiesShipping, returns, refunds, privacy and account policies in full text.
Agent guidance: Ground policy answers in this text instead of improvising.
Try /api/public/v1/policies/api/public/v1/policies/{slug}Fetch a single policy document by slug, e.g. `returns`.
Agent guidance: Quote the exact clause back to the customer.
Try /api/public/v1/policies/returns/api/public/v1/faqsCurated question/answer pairs for common support topics.
Agent guidance: First stop for general questions that need no account data.
Try /api/public/v1/faqs?q=shippingTickets and simulated support actions.
/api/public/v1/support/ticketsPaginated support tickets with customer and order context.
Agent guidance: Check for an existing open ticket before creating another.
Try /api/public/v1/support/tickets?limit=3/api/public/v1/support/ticketsOpens a ticket, linking the customer by email and optionally an order.
Agent guidance: Escalation path when you cannot resolve the request with the other endpoints.
See request body in the OpenAPI spec/api/public/v1/support/tickets/{id}Change status, priority or record a resolution. Accepts TCK number or UUID.
Agent guidance: Close the ticket once the customer confirms the issue is resolved.
See request body in the OpenAPI spec/api/public/v1/support/actions/password-resetSimulates sending a reset email. Always returns success so account existence is never leaked.
Agent guidance: Standard answer for 'I can't log in'.
See request body in the OpenAPI spec/api/public/v1/support/actions/address-changeUpdates the shipping address while the order is still pending or processing.
Agent guidance: Use before the order ships; afterwards offer a return or intercept instead.
See request body in the OpenAPI spec