Cancel order
POST https://pos.paysera.com/eapi/v1/orders/{id}/cancel
Cancel an existing order.
Once cancelled, the order cannot be restored or modified.
Important: Orders can only be cancelled if they are in a cancellable state (e.g., not already completed or processed).
Authorization​
This endpoint requires a Personal Access Token, sent as a Bearer token.
To obtain one, your account needs API permission. Once granted, go to /user/settings in your POS account and create a personal access token.
Authorization Header Format:
Authorization: Bearer YOUR_ACCESS_TOKEN
Example:
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9...
For more details, see the Authentication section.
Parameters​
Path Parameters​
| Name | Type | Required | Description |
|---|---|---|---|
id | string | ✓ | The order ID |
Errors​
This endpoint may return the following errors:
400 - Bad Request​
The request was invalid or cannot be served.
401 - Unauthorized​
Unauthorized
This error was produced by providing incorrect credentials.
403 - Forbidden​
Forbidden
This error indicates you don't have permission to access this resource.
404 - Not Found​
Order not found
This error indicates the requested resource was not found.
409 - Conflict​
Order cannot be cancelled in current state
422 - Unprocessable Entity​
Unprocessable entity
429 - Too Many Requests​
You have exceeded the rate limit. Please try again in a minute.
500 - Internal Server Error​
Internal server error
Example​
Request​
POST https://pos.paysera.com/eapi/v1/orders/{id}/cancel
Authorization: Bearer YOUR_ACCESS_TOKEN
Response​
204 — Order cancelled successfully. This endpoint returns no response body.
AUTHORIZATION: HTTP
REQUEST
RESPONSE
{}