commercetools icon

commercetools

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

Actions671

State → Check if State exists by ID

AI-generated

Summary

Verify the existence of a commercetools State by its ID using a HEAD HTTP request.

Inputs

  • State ID (required) — The unique identifier of the State resource to check for existence.

Output shape

a single JSON object indicating existence with fields 'exists' (boolean), 'statusCode' (HTTP status code), and 'url' (the API endpoint checked).

Returns an object with 'exists' true if the State exists (HTTP 200), or false if it does not (HTTP 404). Throws an error for other HTTP status codes.

Examples

Example 1: Check if a State with ID '12345' exists

Provide the State ID '12345' as input to the 'State ID' parameter of this operation, then execute the node. The output will indicate whether the State exists.

Links

Discussion