تخطَّ إلى المحتوى

Error codes

هذا المحتوى غير متوفر بلغتك بعد.

Every refusal comes in the same envelope, with a code from this list:

{"error": {"code": "SCOPE_MISSING",
"message": "This client does not hold the invoices:read scope. Add it in Settings → Integrations.",
"details": [{"scope": "invoices:read", "code": "SCOPE_MISSING"}],
"request_id": "req_01J9X4Q7T2M8P3NRT6V5WZ",
"retryable": false}}
  • message is written for you, the developer, and may name the field, the scope or the call to make first. Don’t parse it; branch on code.
  • retryable says whether the same call can succeed later. “What it means” below is the plain text the SLFLO console shows for the same code.
  • Quote request_id (also in the X-Request-Id header) when you contact us.
  • A gateway in front of SLFLO may answer 502, 503 or 504 without this envelope. Treat those like INTERNAL: back off and retry, honouring Retry-After when it is sent.
CodeHTTPRetry?What it meansWhat to do
INVALID_REQUEST400 or 422NoThe request is not in the expected form. Check its parameters and body against the API documentation.Fix the call (400) or the data (422, a rule on a pushed record): the message names the field.
IDEMPOTENCY_KEY_REQUIRED400NoThe call had no Idempotency-Key, so it was not applied. Send one with every POST.Send an Idempotency-Key header on every POST, PUT and DELETE.
TOKEN_INVALID401NoThis integration token is not recognised. Check the token set in the ERP.Stop the job and alert. Check the token in your settings.
TOKEN_EXPIRED401NoThis integration token has expired. Create a new one in Settings → Integrations and update the ERP.Stop the job and alert. Rotate the token in Settings → Integrations.
TOKEN_REVOKED401NoThis integration token was revoked. Ask your administrator for a new one.Stop the job and alert. Put the new token in your settings.
COMPANY_SUSPENDED401NoThis company's account is suspended, so its integration tokens are not accepted. Contact SLFLO support.Stop the job and contact us.
SCOPE_MISSING403NoThis integration is not allowed to do that. Add the missing permission to it in Settings → Integrations.Ask the administrator to add the scope named in details to the client.
IP_NOT_ALLOWED403NoCalls from this address are not on the integration's allowlist. Add the address in Settings → Integrations.Call from an address on the client's allow-list, or ask for yours to be added.
NOT_FOUND404NoIt isn't there any more. Refresh and try again.Check the id, path or reference list name.
ALREADY_ACKNOWLEDGED409NoThe ERP already answered this order differently. It can answer again only after the order is sent to the ERP again.The record was already answered differently. Treat it as done unless it is sent again.
ORDER_NOT_AWAITING_ACK409NoThis order is not waiting for the ERP, so there is nothing for the ERP to answer.The order is not waiting for your ERP. Pull filter[ack]=pending for the ones that are.
ERP_MODE_NOT_API409NoThis company's orders are not set to be collected by its ERP, so the ERP cannot answer for them.Order acks need the company in ERP mode API. Ask us to switch it.
EXTERNAL_REF_CONFLICT409NoThat ERP reference already belongs to another record here. Each record answers to one ERP reference.Your key already belongs to another record. Use one key per record; adopt with salflo_id.
BRANCH_ON_ROUTE409NoThis branch is still on a route. Remove it from the route first.Take the branch off its route in the console, then delete it.
REQUEST_IN_PROGRESS409YesThe same call is still being processed. Try again in a few seconds.The first call with this key is still running. Retry shortly with the same key.
UNKNOWN_REFERENCE422NoThat refers to something the ERP has not sent yet. Send it first, then try again.Push what details names first (the call is in the message); nothing was written.
IDEMPOTENCY_KEY_REUSED422NoThat Idempotency-Key was already used for a different request. Use a new key for a new request.A key goes with one request body. Use a new key for a different request.
ERP_STOCK_NOT_ENABLED409NoThis company keeps its stock in SLFLO. Turn on "Stock is managed in your ERP" in Settings → Integrations first.The company keeps its stock in SLFLO. Hold stock sends until an administrator turns on Stock is managed in your ERP.
LOAD_ALREADY_CHECKED409NoThe rep already accepted this load, so its goods can no longer change.The rep already accepted the load. Do not post the edited journal: record the change as a new journal and alert the storekeeper.
LOAD_PARTLY_SOLD409NoSome of this load has already been sold from the van.Part of the load has left the van, so it cannot be changed or cancelled. Record the change as a new journal.
NOT_A_VAN422NoThat place is not a van. Loads and unloads name a van.van names a place that is not a van. Send the van warehouse's SLFLO code (GET /lookup?entity=van).
NOT_A_WAREHOUSE422NoThe place named is not a warehouse: a load comes from a warehouse or another van, and good stock unloads to a warehouse.A load's from names a held-back place, or a good-stock unload's to names a place that is not a warehouse. Send the warehouse's (or the giving van's) SLFLO code.
INSUFFICIENT_VAN_STOCK422NoThe giving van of a van to van doesn't hold all the goods the journal moves.A van to van moves only what the giving van holds in SLFLO; the message names each short line. Check that van's sales since the journal was made, fix the journal and send it again.
SAME_LOCATION422NoThe load's from and van are the same place.from and van are the same place. Fix the journal's warehouses.
UNIT_NOT_OF_PRODUCT422NoThe product isn't kept in that unit in SLFLO.The line's unit is not one of the product's units. Push its product units, or send the base unit.
BATCH_REQUIRED422NoSLFLO tracks this product by lot, and the line has none.SLFLO tracks the product by lot. Send the line's lot.
NOT_TRACKED422NoSLFLO doesn't track this product by lot, and the line names one.SLFLO does not track the product by lot. Leave the line's lot out.
SERIAL_TRACKED422NoSLFLO tracks this product by serial number, which loads and unloads don't take.Serial-tracked products cannot be loaded or unloaded through the API yet.
LOAD_STILL_WAITING409YesA load on this van still waits for the rep to accept or refuse it. The unload goes through once the rep has answered.A load still waits on the van for the rep's answer. Keep the unload and send it again later (same body, any key).
VAN_DAY_NOT_ENDED409YesThe rep hasn't ended today's work day yet. The unload goes through once the rep taps End day.The van's rep has not ended today's work day. Keep the unload and send it again later.
UNLOAD_ALREADY_RECORDED409NoThis unload journal was already recorded with other goods, and its stock has moved. Post the correction as a new journal.The journal was already recorded with other goods and its stock has moved. Post the correction as a new journal.
NOT_QUARANTINE422NoA held-back unload's to is a van or a van's held-back place; held-back goods go to a warehouse's held-back place.A held-back unload's to must be a warehouse's held-back place (or the warehouse itself), not a van's.
NO_QUARANTINE422NoThe van, or the warehouse in to, has no held-back place set up.The van, or the warehouse named in to, has no held-back place. Set one up in SLFLO, or name another warehouse.
RATE_LIMITED429YesToo many attempts. Wait a minute and try again.Wait the Retry-After seconds, then send the same call again.
INTERNAL500YesSomething went wrong on our side. Try again in a moment; if it keeps happening, quote the request number to support.Retry with back-off; quote the request_id if it persists.

INVALID_REQUEST is 400 when the call itself is malformed (an unknown filter, a bad per_page) and 422 when a pushed record breaks a rule (a negative price, a key with a /). How to retry each status is in Retries, 429 and token rotation.