Getting started

Sandbox & testing

There is no separate sandbox address: the same API, called with a mk_test_… key, runs in test mode.

Sandbox vs live#

Test key (sandbox)Live key
Catalog, prices and stockRealReal
Validation (fields, minimum price, stock, COD covers cost, duplicates)✓✓
Order is packed and shipped—✓
Customer confirmation call—✓
Wallet charged / credited—✓
Daily order cap and blocked phone numbers—✓
Status changesYou trigger them with /simulateHappen as the courier moves
WebhooksSent, with "mode": "test"Sent, with "mode": "live"
Works before your account is approved✓—

Moving a test order#

curl -X POST "https://backend.markitmall.com/dropship/v1/orders/{id}/simulate" \
  -H "Authorization: Bearer mk_test_XXXX:sk_test_XXXX" \
  -H "Content-Type: application/json" \
  -d '{
  "status": "DELIVERED"
}'
statusWhat it doesWebhook
CONFIRMEDThe customer confirmed the orderorder.confirmed
PROCESSINGBeing packed—
SHIPPEDAdds a sample tracking number (TEST-TRK-…)order.shipped
DELIVEREDMargin becomes pending, with its release dateorder.delivered
CANCELLEDCancelledorder.cancelled
RETURNEDRefused at the door; shows the shipping chargeorder.returned
/simulate only accepts test keys. A live key gets 422 test_mode_only.

A test plan before going live#

ScenarioHow
Happy pathOrder → CONFIRMED → SHIPPED → DELIVERED; your store shows tracking and marks the order complete
Refused parcelOrder → SHIPPED → RETURNED; your store marks it returned
CancellationCancel from your store → POST /orders/{id}/cancel
Price too lowSend resalePrice below minResalePrice → 422 price_below_minimum
Out of stockOrder more than stock → 422 out_of_stock
Retry safetySend the same order twice with the same Idempotency-Key → one order
Webhook securityChange one byte of a delivered body → your endpoint must reject it
Duplicate webhookProcess the same X-MarkitMall-Event-Id twice → handled once

Trying calls in the browser#

Every endpoint in the API reference has a Try it in the sandbox panel. Paste your test key (mk_test_…:sk_test_…) once — every panel on the page uses it — fill in the fields and send a real request to the sandbox. The id an order call returns is filled in for the next step, so you can create an order and then simulate, cancel or read it without copying ids.

Try it only accepts test keys. You can also import openapi.json into Postman.