Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ably-common
Submodule ably-common updated 128 files
47 changes: 24 additions & 23 deletions src/pages/docs/platform/errors/codes.mdx

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions src/pages/docs/platform/errors/codes/10000-no-error.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/10000.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A placeholder code indicating success, used where an error code is expected but the operation completed normally. It does not represent a failure.

## What you should do

Nothing. Code 10000 is not a failure: it is a placeholder used where an error code is expected but the operation completed normally. If it surfaces as though it were an error, the issue is in how the result is being interpreted, not in the operation itself.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/101000.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A space could not be created or referenced because no name was supplied.

## What you should do

Pass a non-empty name when getting a [space](https://ably.com/docs/spaces/space). Every space is identified by its name, so the call needs one.

## Why it happens

A space was requested with an empty or missing name. A space has to be identified by a non-empty name, so the request could not be resolved to one.

## What you'll see

The error is reported with code 101000 and HTTP status 400. The message is `must have a non-empty name for the space`.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/101001.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

An operation was attempted that requires having first entered the space. In Ably Spaces, actions such as updating a member's location or profile are only available once the space has been entered.

## What you should do

[Enter the space](https://ably.com/docs/spaces/space#enter) before performing the operation. Operations such as updating a member's location or profile act on your membership of the space, so they only work once you have entered it.

## Why it happens

The operation requires the client to have entered the space, and it had not. Entering the space establishes the membership these operations act on.

## What you'll see

The error is reported with code 101001 and HTTP status 400. The message is `must enter a space to perform this operation`.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/101002.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A lock could not be requested because a request for the same lock is already in progress. In Ably Spaces, a member may only have one outstanding request for a given lock at a time.

## What you should do

Wait for the pending [lock](https://ably.com/docs/spaces/locking) request to resolve before requesting the same lock again. A member can have only one outstanding request for a given lock, so let the first attempt succeed or fail rather than issuing another alongside it.

## Why it happens

A lock was requested while a request for the same lock by the same member was still in progress. Lock acquisition is asynchronous, and only one request per lock can be outstanding at a time.

## What you'll see

The error is reported with code 101002 and HTTP status 400. The message is `lock request already exists`.
12 changes: 12 additions & 0 deletions src/pages/docs/platform/errors/codes/101003-lock-already-held.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/101003.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A lock could not be acquired because it is currently held by another member. In Ably Spaces, only one member can hold a given lock at a time, and it must be released before another can take it.

## What you should do

Treat the [lock](https://ably.com/docs/spaces/locking) as unavailable and handle that in your application, for example by waiting until it is released and trying again, or by showing the component as locked by someone else. Contention is expected: a lock exists precisely so that only one member holds it at a time.

## Why it happens

The lock was already held by another member when it was requested. Only one member can hold a given lock at a time, and it must be released before another member can acquire it.

## What you'll see

The error is reported with code 101003 and HTTP status 400. The message is `lock is currently locked`.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/101004.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A lock that appeared to be acquired was invalidated because another member requested the same lock concurrently and now holds it.

## What you should do

Treat the [lock](https://ably.com/docs/spaces/locking) as not held by you and handle losing it, for example by releasing the component you were editing. When two members request the same lock at nearly the same time, only one can win, so your application should be prepared for a request that briefly looked successful to be invalidated.

## Why it happens

Another member requested the same lock concurrently and now holds it, which invalidated this member's request even though it had appeared to succeed. Only one member can hold a lock, so a concurrent request is resolved in favor of a single winner.

## What you'll see

The error is reported with code 101004 and HTTP status 400. The message is `lock was invalidated by a concurrent lock request which now holds the lock`.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
---
title: "103001: Push notification retry limit reached"
meta_description: "The push notification was not delivered because the configured retry limit was reached after repeated unsuccessful delivery attempts. The underlying failures are typically transient provider outages, rate limits, or network errors."
meta_description: "The push notification was not delivered because the configured retry limit was reached after repeated unsuccessful delivery attempts. The underlying failures are typically transient, such as provider outages, rate limits, or network errors."
identifier: "push_publish_retries_exhausted"
redirect_from:
- /docs/platform/errors/codes/103001
---

{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/103001.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The push notification was not delivered because the configured retry limit was reached after repeated unsuccessful delivery attempts. The underlying failures are typically transient provider outages, rate limits, or network errors.
The push notification was not delivered because the configured retry limit was reached after repeated unsuccessful delivery attempts. The underlying failures are typically transient, such as provider outages, rate limits, or network errors.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
---
title: "103004: Push notification rejected by provider"
meta_description: "The push notification was not delivered because the provider APNs, FCM, or WebPush rejected the request due to a problem with the payload or delivery parameters. Typical causes include an oversized payload, a disallowed topic, or an unsupported field."
meta_description: "The push notification was not delivered because the provider (APNs, FCM, or WebPush) rejected the request due to a problem with the payload or delivery parameters. Typical causes include an oversized payload, a disallowed topic, or an unsupported field."
identifier: "push_notification_rejected_by_provider"
redirect_from:
- /docs/platform/errors/codes/103004
---

{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/103004.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The push notification was not delivered because the provider APNs, FCM, or WebPush rejected the request due to a problem with the payload or delivery parameters. Typical causes include an oversized payload, a disallowed topic, or an unsupported field.
The push notification was not delivered because the provider (APNs, FCM, or WebPush) rejected the request due to a problem with the payload or delivery parameters. Typical causes include an oversized payload, a disallowed topic, or an unsupported field.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
---
title: "103005: Push device token invalid"
meta_description: "The push notification was not delivered because the provider APNs, FCM, or WebPush rejected the device's push token as invalid for the configured application. The token may have been issued under different credentials or for a different application."
meta_description: "The push notification was not delivered because the provider (APNs, FCM, or WebPush) rejected the device's push token as invalid for the configured application. The token may have been issued under different credentials or for a different application."
identifier: "push_device_token_invalid"
redirect_from:
- /docs/platform/errors/codes/103005
---

{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/103005.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The push notification was not delivered because the provider APNs, FCM, or WebPush rejected the device's push token as invalid for the configured application. The token may have been issued under different credentials or for a different application.
The push notification was not delivered because the provider (APNs, FCM, or WebPush) rejected the device's push token as invalid for the configured application. The token may have been issued under different credentials or for a different application.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
---
title: "103006: Push transport not configured"
meta_description: "The push notification was not delivered because the device's push notification provider APNs, FCM, or WebPush has no credentials configured on the application. No deliveries can be made through that provider until the credentials are present."
meta_description: "The push notification was not delivered because the device's push notification provider (APNs, FCM, or WebPush) has no credentials configured on the application. No deliveries can be made through that provider until the credentials are present."
identifier: "push_transport_not_configured"
redirect_from:
- /docs/platform/errors/codes/103006
---

{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/103006.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The push notification was not delivered because the device's push notification provider APNs, FCM, or WebPush has no credentials configured on the application. No deliveries can be made through that provider until the credentials are present.
The push notification was not delivered because the device's push notification provider (APNs, FCM, or WebPush) has no credentials configured on the application. No deliveries can be made through that provider until the credentials are present.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
---
title: "103007: Push notification provider unreachable"
meta_description: "The push notification was not delivered because the provider APNs, FCM, or WebPush could not be reached, returned a server error, or sent a response that could not be processed. The condition is usually transient."
meta_description: "The push notification was not delivered because the provider (APNs, FCM, or WebPush) could not be reached, returned a server error, or sent a response that could not be processed. The condition is usually transient."
identifier: "push_notification_provider_unreachable"
redirect_from:
- /docs/platform/errors/codes/103007
---

{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/103007.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The push notification was not delivered because the provider APNs, FCM, or WebPush could not be reached, returned a server error, or sent a response that could not be processed. The condition is usually transient.
The push notification was not delivered because the provider (APNs, FCM, or WebPush) could not be reached, returned a server error, or sent a response that could not be processed. The condition is usually transient.
12 changes: 12 additions & 0 deletions src/pages/docs/platform/errors/codes/20000-general-error.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/20000.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A generic error that does not correspond to a more specific code. It is used as a catch-all when the condition could not be classified more precisely.

## What you should do

Rely on the accompanying message and HTTP status for the specifics, since 20000 itself only signals that the condition didn't map to a more specific code. Capture the message and status, and if the cause isn't clear, [contact Ably support](https://ably.com/support) with them.

## Why it happens

The condition could not be classified under a more specific error code, so the general code was used. The accompanying message describes the actual problem.

## What you'll see

The error is reported with code 20000, alongside a message and HTTP status that describe the specific condition.
12 changes: 12 additions & 0 deletions src/pages/docs/platform/errors/codes/40000-bad-request.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/40000.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The request was rejected because it was invalid and could not be processed.

## What you should do

Correct the request and resend it. 40000 is the generic code for a request Ably could not process, so start from the accompanying message, which states what was wrong.

## Why it happens

The request was malformed or otherwise invalid in a way that doesn't have a more specific error code. The accompanying message describes the specific problem.

## What you'll see

The error is reported with code 40000 and HTTP status 400. The message describes what made the request invalid.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/40001.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

The body of the request could not be processed because it was invalid, missing required fields, or not in the expected format.

## What you should do

Correct the request body so it matches what the endpoint expects, then resend. Start from the accompanying error message: it names the specific problem, such as a field of the wrong type or a missing required field.

## Why it happens

The body of the request could not be parsed or failed validation. Common cases are a malformed or non-JSON body, a missing required field, or a value of the wrong type. It most often appears on token requests, where a field is absent or not in the expected form.

## What you'll see

The error is reported with code 40001 and HTTP status 400. The message varies with the cause and usually names the offending part, for example `invalid request body: ...`.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/40003.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A parameter in the request was invalid, such as a value of the wrong type, outside the allowed range, or otherwise unacceptable for that parameter.

## What you should do

Correct the offending parameter and resend. The accompanying message names the parameter and the problem, so start there.

## Why it happens

A parameter in the request held a value that isn't acceptable: the wrong type, outside the allowed range, or otherwise invalid for that parameter. Examples include an out-of-range `limit` on a history or presence query, an unparseable pagination cursor or message serial, or a token `ttl` above the permitted maximum.

## What you'll see

The error is reported with code 40003 and HTTP status 400. The message identifies the parameter, for example `Invalid limit param` or `invalid serial: ...`.
12 changes: 12 additions & 0 deletions src/pages/docs/platform/errors/codes/40005-invalid-credential.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/40005.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

An API key or token supplied with the request could not be read because it was not in the expected form. This is distinct from a key or token that is well-formed but unauthorized.

## What you should do

Check the API key or token the client was configured with. The value couldn't be read at all, so the fix is to supply a correctly-formed credential, not to adjust its permissions. Copy the key from the [Ably dashboard](https://ably.com/accounts/any/apps/any/app_keys) again in case it was truncated or picked up stray whitespace.

## Why it happens

The credential supplied was not in the expected form, so it couldn't be parsed. Common causes are a key or token that was truncated, had characters added or removed, or was passed in the wrong field. This is distinct from a well-formed credential that is rejected as unauthorized.

## What you'll see

The error is reported with code 40005 and HTTP status 400. The message names the unreadable value, for example `Invalid key in request: ...` or `Invalid accessToken in request: ...`.
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,15 @@ redirect_from:
{/* AUTOGENERATED — DO NOT EDIT. Generated from ably-common/errors/codes/40006.md by bin/generate-error-pages.ts; run `yarn generate:errors` to update. */}

A published message referenced a connection by an ID or key that was invalid or did not match, so the message was rejected.

## What you should do

When [publishing on behalf of a realtime connection](https://ably.com/docs/pub-sub/advanced#publish-on-behalf), make sure the `connectionKey` you publish with is the current key of that connection, and that any `connectionId` set on a message matches the publishing connection. Correct the mismatched value and resend.

## Why it happens

A published message referenced a connection that couldn't be validated. Usual causes are a malformed or stale `connectionKey`, a REST publisher and realtime client that belong to different Ably apps or use different client IDs, or a manually constructed message whose `connectionId` doesn't match the current connection.

## What you'll see

The error is reported with code 40006 and HTTP status 400. The message is typically `Malformed message; invalid connectionId` or `Malformed message; mismatched connectionId`.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ A message was rejected because it exceeded the maximum permitted size. When seve

Reduce the size of what you publish so it falls within the limit. Because it is rejected outright and not retried, it has to be made smaller to get through. If you publish several messages in a single call, the limit applies to their combined size, so sending fewer messages per call is one way to do that.

The default maximum is 64 KB, but the exact figure depends on your account; check it against your account's [limits](https://ably.com/docs/general/limits). If your use case genuinely needs larger messages, you can request a higher limit.
The default maximum is 64 KB, but the exact figure depends on your account; check it against your account's [limits](https://ably.com/docs/platform/pricing/limits). If your use case genuinely needs larger messages, you can request a higher limit.

## Why it happens

Expand Down
Loading