Error codes

Every error returns a JSON body whose error object holds code, message and request_id. Codes are stable; match on code, never on message. 402 means a billing problem (quota or payment) and is fixed with money; 429 means you are going too fast and is fixed by waiting Retry-After seconds.

CodeHTTP statusMessageRemediation
invalid_body400Request body must be valid JSONSend valid JSON with Content-Type: application/json. house_number is a string, not a number.
invalid_idempotency_key400Idempotency-Key must be 1-255 visible ASCII charactersSend a unique value of 1-255 visible ASCII characters (for example a UUID).
idempotency_key_reused422This Idempotency-Key was already used with a different request bodyUse a new key for a different body; replay the exact same body only with the same key.
invalid_parameter400Invalid or out-of-range parameterCheck the bounds: limit between 1 and 25 (autocomplete, search); range and group only with the documented values (usage).
invalid_postal_code400Postal code must be exactly 6 digitsSend exactly 6 digits, no spaces.
invalid_query400Query must be at least 2 charactersSend q with at least 2 characters.
missing_address400Provide either 'address' (structured) or 'freeform' (string)Fill in one of the two fields.
ambiguous_input400Provide either 'address' or 'freeform', not bothSend a single address format.
missing_locality400locality is requiredAdd locality to the request body.
house_number_requires_street400house_number requires streetSend street together with house_number.
invalid_house_number400house_number must not be emptyOmit the field or send a non-empty number (string).
missing_file_url400file_url is requiredAdd file_url for the batch job.
invalid_callback_url400options.callback_url must be an https URL on a public hostUse a public https URL; private, loopback and link-local targets are rejected.
field_too_long400Text fields must be at most 256 charactersShorten the field named in the message.
missing_credentials401Authentication requiredSend Authorization: Bearer YOUR_API_KEY on every request.
invalid_api_key401Invalid or revoked API keyRotate the key in the dashboard and update your secret store.
quota_exceeded402Monthly request quota exceeded — upgrade your plan to continuePlans without overage stop at the monthly quota. Upgrade or wait for the reset (X-Posty-Period-Resets-At header). Do not auto-retry.
payment_required402Payment overdue — please update your payment method to continueUpdate the payment method in the dashboard (X-Posty-Grace-Period-Ends header).
forbidden403Access deniedThe resource belongs to another organization; use a key of the right organization.
subscription_suspended403Subscription suspended due to non-paymentSettle the overdue invoice in the dashboard.
not_found404The requested resource does not existCheck the id you sent.
postal_code_not_found404No data found for the requested postal codeCheck the postal code or use search.
locality_not_found404Locality not foundCheck the locality name and county.
method_not_allowed405Method not allowedUse the HTTP method documented for the endpoint.
job_not_complete409Job is not yet completePoll the job status until it is done.
results_expired410Results have been deleted after the retention periodResults are kept 30 days after completion; resubmit the job.
payload_too_large413Request body exceeds 64 KiBSend a smaller body or use batch.
rate_limit_exceeded429Rate limit exceeded, please slow downWait the Retry-After seconds and honour the X-RateLimit-* headers.
internal_error500Internal server errorSend request_id to support@posty.ro for investigation.
request_timeout504Request timed out — please retryRetry idempotent requests. POST /v1/addresses/batch is not atomic: a retry may create a duplicate job.

© 2026 posty.ro