commercetools icon

commercetools

Interact with the commercetools API. Operations are auto-generated from the official Postman collection.

Actions671

Order → Check if Order exists by OrderNumber

AI-generated

Summary

Check existence of an order by its order number using a HEAD request to the commercetools API.

Inputs

  • Order Number (required) — The unique order number to check for existence.

Output shape

a single JSON object indicating existence status

Returns an object with properties 'exists' (boolean), 'statusCode' (HTTP status), and 'url' (API endpoint used). If the order exists, 'exists' is true and statusCode is 200; if not, 'exists' is false and statusCode is 404. API errors other than 404 are thrown as NodeApiError.

Examples

Example 1: Check if an order exists by order number '12345'

Set resource to 'Order', operation to 'Check if Order exists by OrderNumber', and provide '12345' as 'Order Number'. The node executes a HEAD request to the commercetools orders endpoint for the given order number to determine existence.

Links

Discussion