amount_ invalid
The amount is not a valid decimal string.
On this page
HTTP status: 422 Unprocessable Entity. Retrying the same request unchanged fails the same way.
Why it happens
- The amount was sent as a JSON number instead of a string, such as 12.5 instead of "12.5".
- It has a sign, an exponent or spaces, or it is empty.
- It is too large to represent.
What to do
Send a plain decimal string in the asset's units, such as "12.5".
Example
The response is application/problem+json. Branch on code, never on title or detail. See errors for the format.
{
"type": "https://docs.nowgate.io/errors/amount_invalid",
"title": "Unprocessable Entity",
"status": 422,
"detail": "What exactly was wrong, in a sentence.",
"instance": "/v1/payments",
"code": "amount_invalid",
"request_id": "req_01jc3xb1n6f0q2w8e4r7t5y9v3"
}