Preview Source Code for Sales Order
GET/api/veracore/integration-instances/:integration_instance/source-code-mappings/preview
Preview which Veracore source code would be applied to a given sales order under the current mappings. This is a read-only computation — nothing is stored and no call is made to the Veracore API.
Any valid API token can call this endpoint — no specific scope required. Manage tokens.
Resolution order:
- A mapping matching the order's sales channel and sub sales channel (
matched_type: "sub_channel"). - The sales channel's catch-all mapping with no sub channel (
matched_type: "catch_all"). - No match —
source_codeandmatched_typearenull.
The response also includes the sales channel and sub channel context used for resolution so you can see why a mapping did or did not match.
Errors
404when no sales order exists with the givensales_order_id, or the integration instance does not exist.
Authentication: Requires Bearer token.
Request
Responses
- 200
- 401
- 403
- 404
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not Found
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.