Downstream Support
About 734 words
xstock is more than a bare API. If you already run a mature third-party storefront program, you usually don't need to write any code: as long as that program can connect to an upstream supplier, you can enter your xstock connection details in its admin panel and start using it.
This group of documents explains which storefront programs xstock supports, how to connect each one, and how to reuse the same adapter capabilities when you build your own store.
Currently supported
| Storefront program | Type | Status | Integration approach | Docs |
|---|---|---|---|---|
| Dujiao-Next | Open-source digital goods storefront | Supported | Upstream protocol + xstock adapter layer | Dujiao-Next integration |
| ACG-Faka | Open-source card-key storefront | Supported | Store-sharing protocol + adapter component | ACG-Faka integration |
| Other programs | — | Under evaluation / on demand | Requires their upstream protocol documentation | Other downstream types |
Dujiao-Next and ACG-Faka are the programs formally integrated today; everything else is evaluated on demand. If your storefront program is not on the list, you can either connect your own store directly to the API, or submit a support request.
Three integration approaches
| Approach | Suited to | Code changes | Description |
|---|---|---|---|
| The storefront program's native upstream protocol | Stores already running Dujiao-Next or similar | No | Just enter the connection details in the admin panel; the xstock adapter layer handles protocol translation |
| Own storefront with direct API access | In-house systems | Yes | Connect straight to /dist/api/v1 with the API reference |
| Adapter / middleware | Multiple systems coexisting | A little | You build a translation layer that maps the xstock API onto your own internal protocol |
Which one to choose
If you can use an off-the-shelf storefront program that supports upstream integration, choose the first approach. If you need deep customization of product presentation, pricing or membership, build your own store and connect directly to the API. The two can coexist: some products sold through a storefront program, others through your own system.
Relationship to the API docs
- Downstream support (this group): for the "use an off-the-shelf storefront program" scenario; covers connection settings, capability boundaries and acceptance checks.
- API reference: for building your own store; covers commands, signatures, fields and error codes.
Both rest on the same underlying supply capability and differ only in packaging: the storefront program sees its own upstream protocol, which the xstock adapter layer translates into /dist/api/v1/{cmd} calls.
General prerequisites
Whichever approach you take, first complete the following in the xstock portal:
- Register and open a distributor account;
- Create a store and obtain its API Key / Secret;
- Configure the callback URL (HTTPS, verifiable);
- Top up your balance as needed — funds are held when an order is placed and charged on delivery, with no credit overdraft.
See Onboarding for the full process.
Supported capabilities
Through the adapter layer, storefront programs get the same capabilities as the native API:
| Capability | Description |
|---|---|
| Connectivity check | Validates the URL, Key/Secret and signature; returns site name, balance, currency and tier |
| Products and categories | Category tree and product list (including SKUs, images, tags and multi-currency prices) |
| Availability | Query the sellable quantity per product, down to SKU level |
| Quotes | Multi-currency unit prices calculated with tier discounts |
| Order / query / cancel | Idempotent ordering, order lookup by order number or request ID, cancellation before delivery |
| Delivery | Deliverables returned with the order query, attributed by order line and SKU |
| After-sales | Open support tickets and query the full history by ticket number |
| Callbacks | Push events for order acceptance, delivery, completion, cancellation and rejection |
Capability boundaries
The following remain the storefront program's responsibility; xstock does not handle them:
- Consumer-facing payment, refunds and invoicing;
- Consumer accounts, membership tiers and marketing campaigns;
- Re-editing and localizing product copy;
- The consumer-facing after-sales interface (the platform only handles tickets you open against it).
Requesting support for a new storefront program
Provide the following information and we will assess protocol gaps and effort:
- Program name, official website and current version;
- Its upstream integration protocol documentation (endpoint paths, authentication, signature, fields, callbacks);
- The capability scope you want (products and ordering only, or also after-sales and multi-currency);
- Your expected integration timeline.
Once the assessment passes, the adapter layer only needs one new protocol mapping; the storefront program keeps its own configuration. See Apply for access to get in touch.