> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.pay4power.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.pay4power.com/_mcp/server.

# Response Model

> Understand common Pay4Power response fields and how to handle them.

Most Pay4Power responses use a consistent envelope so your integration can handle success, validation, and processing states predictably.

| Field           | Meaning                                                                   |
| --------------- | ------------------------------------------------------------------------- |
| `success`       | Indicates whether the API request was accepted or completed successfully. |
| `message`       | Human-readable status or error summary.                                   |
| `errors`        | Null on success, otherwise an array of error details.                     |
| `statusCode`    | HTTP-style status code returned inside the response body.                 |
| `correlationId` | Identifier useful for support, tracing, and reconciliation.               |
| `data`          | Product-specific response payload.                                        |

## Success handling

Use both HTTP status and the response body. A successful HTTP response can still represent a business-level pending or failed state depending on the endpoint and payload.

## Pending handling

When a vend endpoint returns a pending or accepted response, store the transaction reference and call the requery endpoint until the transaction reaches a final state.

## Error handling

Display clear, product-specific errors to operators or customers, but keep raw `correlationId` values in your logs so support can trace the request.