Errors and limits

Errors

Errors are application/problem+json with a stable code. Branch on the code; the detail is for a person reading a log and may be reworded.

HTTP/1.1 402 Payment Required
Content-Type: application/problem+json

{
  "title": "Payment required",
  "status": 402,
  "detail": "This month's credits are used up. Messages can be sent again when the plan renews or is upgraded.",
  "code": "credit_limit_reached"
}
codeHTTPMeaning
missing_api_key401No key was sent.
invalid_api_key401The key is wrong, revoked or expired.
insufficient_scope403The key lacks the read or send permission this call needs.
not_found404No such account or conversation — or it is not yours; the two look the same.
invalid_request400 / 422The request is malformed, or a pagination cursor is no longer reachable. For a file: more than one, not in a part named file, no file name, empty, or a multipart body that cannot be read.
unsupported_operation422The channel cannot do this — for example a file on WhatsApp. Check the account's capabilities first.
attachment_type_not_allowed422The file is not a PDF, PNG or JPEG, or its content is not the type it says it is.
attachment_too_large413The file is over the limit in capabilities.maxAttachmentBytes (10 MB).
attachment_needs_conversation422LinkedIn takes a file only into a conversation that has started. Send the text first, the file once that conversation exists.
account_not_ready409The account is signed out or needs a new password. Fix it in the dashboard.
credit_limit_reached402This month's credits are used up.
attachment_storage_unavailable503The file could not be stored, so nothing was queued. Not the channel being down: wait for Retry-After and send again with the same Idempotency-Key. While storage is not set up, capabilities.attachments is false.
too_many_line_breaks400A LinkedIn message has more than 20 line breaks (counted after runs of blank lines are collapsed). Other control characters in a message are invalid_request.
remote_account_not_found404Adopting an account: linkedin-api has no account with that id for this service's key. It must exist under the same linkedin-api tenant.
remote_account_already_linked409Adopting an account: that LinkedIn account is already linked here, to you or to anyone else.
plan_required403Creating, signing in, signing out and deleting accounts through the API is part of the Enterprise plan.
account_limit_reached403Your plan's connected accounts are all in use. Delete one or upgrade to create another.
authentication_not_waiting409You submitted a code, but that sign-in is not waiting for one. Start again.
idempotency_key_required400A send needs an Idempotency-Key header.
idempotency_key_reused422That key was already used for a different request.
idempotency_key_in_progress409The first request with that key is still running. Wait, then retry with the same key.
rate_limited429Too many requests. Wait for Retry-After.
channel_unavailable502 / 503WhatsApp, Telegram or LinkedIn could not be reached or refused it. Retry later.

Rate limits

Each key gets 120 reads and 30 sends per minute, counted separately, so a polling job can't starve your sends. Over the limit you get 429 with a Retry-After header in seconds. LinkedIn adds its own pacing on reads, and holds at most 50 unsent messages per account.