Skip to content

XmtpError

Defined in: sdks/node/dist/public-values.gen.d.ts:1661

A failure from the XMTP SDK. Its subclass names the failure variant. details.code keeps the Rust cause code.

  • Error

new XmtpError(details): XmtpError

Defined in: sdks/node/dist/public-values.gen.d.ts:1663

ErrorDetails

XmtpError

Error.constructor

optional cause?: unknown

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2022.error.d.ts:24

Error.cause


readonly details: ErrorDetails

Defined in: sdks/node/dist/public-values.gen.d.ts:1662


message: string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1075

Error.message


name: string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1074

Error.name


optional stack?: string

Defined in: node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1076

Error.stack


readonly static Attachment: typeof XmtpErrorAttachment

Defined in: sdks/node/dist/public-values.gen.d.ts:1705


readonly static AuthRequired: typeof XmtpErrorAuthRequired

Defined in: sdks/node/dist/public-values.gen.d.ts:1679


readonly static BackendMismatch: typeof XmtpErrorBackendMismatch

Defined in: sdks/node/dist/public-values.gen.d.ts:1677


readonly static CallbackFailed: typeof XmtpErrorCallbackFailed

Defined in: sdks/node/dist/public-values.gen.d.ts:1683


readonly static Cancelled: typeof XmtpErrorCancelled

Defined in: sdks/node/dist/public-values.gen.d.ts:1723


readonly static ChainNotAccepted: typeof XmtpErrorChainNotAccepted

Defined in: sdks/node/dist/public-values.gen.d.ts:1680


readonly static ChannelNotConfigured: typeof XmtpErrorChannelNotConfigured

Defined in: sdks/node/dist/public-values.gen.d.ts:1690


readonly static ClientClosed: typeof XmtpErrorClientClosed

Defined in: sdks/node/dist/public-values.gen.d.ts:1664


readonly static ClientVersionTooOld: typeof XmtpErrorClientVersionTooOld

Defined in: sdks/node/dist/public-values.gen.d.ts:1678


readonly static CodecDecodeFailed: typeof XmtpErrorCodecDecodeFailed

Defined in: sdks/node/dist/public-values.gen.d.ts:1715


readonly static CodecEncodeFailed: typeof XmtpErrorCodecEncodeFailed

Defined in: sdks/node/dist/public-values.gen.d.ts:1713


readonly static CodecNotFound: typeof XmtpErrorCodecNotFound

Defined in: sdks/node/dist/public-values.gen.d.ts:1714


readonly static ConfigurationInvalid: typeof XmtpErrorConfigurationInvalid

Defined in: sdks/node/dist/public-values.gen.d.ts:1676


readonly static ConfigurationUnavailable: typeof XmtpErrorConfigurationUnavailable

Defined in: sdks/node/dist/public-values.gen.d.ts:1675


readonly static ConsumerOwned: typeof XmtpErrorConsumerOwned

Defined in: sdks/node/dist/public-values.gen.d.ts:1701


readonly static Credential: typeof XmtpErrorCredential

Defined in: sdks/node/dist/public-values.gen.d.ts:1674


readonly static CredentialCallbackFailed: typeof XmtpErrorCredentialCallbackFailed

Defined in: sdks/node/dist/public-values.gen.d.ts:1682


readonly static CredentialExhausted: typeof XmtpErrorCredentialExhausted

Defined in: sdks/node/dist/public-values.gen.d.ts:1684


readonly static CredentialMissing: typeof XmtpErrorCredentialMissing

Defined in: sdks/node/dist/public-values.gen.d.ts:1685


readonly static CredentialRejected: typeof XmtpErrorCredentialRejected

Defined in: sdks/node/dist/public-values.gen.d.ts:1681


readonly static DuplicateField: typeof XmtpErrorDuplicateField

Defined in: sdks/node/dist/public-values.gen.d.ts:1709


readonly static ForeignCursor: typeof XmtpErrorForeignCursor

Defined in: sdks/node/dist/public-values.gen.d.ts:1703


readonly static HandleLimitReached: typeof XmtpErrorHandleLimitReached

Defined in: sdks/node/dist/public-values.gen.d.ts:1722


readonly static HandleNotAllowed: typeof XmtpErrorHandleNotAllowed

Defined in: sdks/node/dist/public-values.gen.d.ts:1720


readonly static HandleTaken: typeof XmtpErrorHandleTaken

Defined in: sdks/node/dist/public-values.gen.d.ts:1719


readonly static HandleTooSoon: typeof XmtpErrorHandleTooSoon

Defined in: sdks/node/dist/public-values.gen.d.ts:1721


readonly static IdentityMismatch: typeof XmtpErrorIdentityMismatch

Defined in: sdks/node/dist/public-values.gen.d.ts:1706


readonly static IdentityNotFound: typeof XmtpErrorIdentityNotFound

Defined in: sdks/node/dist/public-values.gen.d.ts:1667


readonly static InvalidArgument: typeof XmtpErrorInvalidArgument

Defined in: sdks/node/dist/public-values.gen.d.ts:1687


readonly static InvalidCursor: typeof XmtpErrorInvalidCursor

Defined in: sdks/node/dist/public-values.gen.d.ts:1702


readonly static InvalidInput: typeof XmtpErrorInvalidInput

Defined in: sdks/node/dist/public-values.gen.d.ts:1665


readonly static Lagged: typeof XmtpErrorLagged

Defined in: sdks/node/dist/public-values.gen.d.ts:1700


readonly static MalformedEnvelope: typeof XmtpErrorMalformedEnvelope

Defined in: sdks/node/dist/public-values.gen.d.ts:1716


readonly static MigrationFailed: typeof XmtpErrorMigrationFailed

Defined in: sdks/node/dist/public-values.gen.d.ts:1670


readonly static MigrationOutput: typeof XmtpErrorMigrationOutput

Defined in: sdks/node/dist/public-values.gen.d.ts:1672


readonly static MigrationRecordRead: typeof XmtpErrorMigrationRecordRead

Defined in: sdks/node/dist/public-values.gen.d.ts:1671


readonly static MigrationUnsupportedSchema: typeof XmtpErrorMigrationUnsupportedSchema

Defined in: sdks/node/dist/public-values.gen.d.ts:1669


readonly static NotificationApi: typeof XmtpErrorNotificationApi

Defined in: sdks/node/dist/public-values.gen.d.ts:1695


readonly static NotificationGroup: typeof XmtpErrorNotificationGroup

Defined in: sdks/node/dist/public-values.gen.d.ts:1697


readonly static NotificationNotFound: typeof XmtpErrorNotificationNotFound

Defined in: sdks/node/dist/public-values.gen.d.ts:1694


readonly static NotificationStorage: typeof XmtpErrorNotificationStorage

Defined in: sdks/node/dist/public-values.gen.d.ts:1696


readonly static NotUserField: typeof XmtpErrorNotUserField

Defined in: sdks/node/dist/public-values.gen.d.ts:1708


readonly static OutOfRange: typeof XmtpErrorOutOfRange

Defined in: sdks/node/dist/public-values.gen.d.ts:1688


readonly static PermissionDenied: typeof XmtpErrorPermissionDenied

Defined in: sdks/node/dist/public-values.gen.d.ts:1686


readonly static PublishedButUnconfirmed: typeof XmtpErrorPublishedButUnconfirmed

Defined in: sdks/node/dist/public-values.gen.d.ts:1717


readonly static RecoveryExhausted: typeof XmtpErrorRecoveryExhausted

Defined in: sdks/node/dist/public-values.gen.d.ts:1698


readonly static RequestTimeout: typeof XmtpErrorRequestTimeout

Defined in: sdks/node/dist/public-values.gen.d.ts:1693


readonly static ResourceExhausted: typeof XmtpErrorResourceExhausted

Defined in: sdks/node/dist/public-values.gen.d.ts:1692


readonly static Signer: typeof XmtpErrorSigner

Defined in: sdks/node/dist/public-values.gen.d.ts:1673


static stackTraceLimit: number

Defined in: node_modules/.pnpm/@[email protected]/node_modules/@types/node/globals.d.ts:68

The Error.stackTraceLimit property specifies the number of stack frames collected by a stack trace (whether generated by new Error().stack or Error.captureStackTrace(obj)).

The default value is 10 but may be set to any valid JavaScript number. Changes will affect any stack trace captured after the value has been changed.

If set to a non-number value, or set to a negative number, stack traces will not capture any frames.

Error.stackTraceLimit


readonly static Storage: typeof XmtpErrorStorage

Defined in: sdks/node/dist/public-values.gen.d.ts:1699


readonly static StorageBusy: typeof XmtpErrorStorageBusy

Defined in: sdks/node/dist/public-values.gen.d.ts:1668


readonly static StorageLocation: typeof XmtpErrorStorageLocation

Defined in: sdks/node/dist/public-values.gen.d.ts:1704


readonly static StorageLocationRequired: typeof XmtpErrorStorageLocationRequired

Defined in: sdks/node/dist/public-values.gen.d.ts:1666


readonly static TaskRunnerDisabled: typeof XmtpErrorTaskRunnerDisabled

Defined in: sdks/node/dist/public-values.gen.d.ts:1691


readonly static TypeChanged: typeof XmtpErrorTypeChanged

Defined in: sdks/node/dist/public-values.gen.d.ts:1712


readonly static TypeMismatch: typeof XmtpErrorTypeMismatch

Defined in: sdks/node/dist/public-values.gen.d.ts:1711


readonly static Unimplemented: typeof XmtpErrorUnimplemented

Defined in: sdks/node/dist/public-values.gen.d.ts:1689


readonly static Unknown: typeof XmtpErrorUnknown

Defined in: sdks/node/dist/public-values.gen.d.ts:1724


readonly static UnknownField: typeof XmtpErrorUnknownField

Defined in: sdks/node/dist/public-values.gen.d.ts:1707


readonly static UnsupportedType: typeof XmtpErrorUnsupportedType

Defined in: sdks/node/dist/public-values.gen.d.ts:1710


readonly static UserLimitExceeded: typeof XmtpErrorUserLimitExceeded

Defined in: sdks/node/dist/public-values.gen.d.ts:1718

static captureStackTrace(targetObject, constructorOpt?): void

Defined in: node_modules/.pnpm/@[email protected]/node_modules/@types/node/globals.d.ts:52

Creates a .stack property on targetObject, which when accessed returns a string representing the location in the code at which Error.captureStackTrace() was called.

const myObject = {};
Error.captureStackTrace(myObject);
myObject.stack; // Similar to `new Error().stack`

The first line of the trace will be prefixed with ${myObject.name}: ${myObject.message}.

The optional constructorOpt argument accepts a function. If given, all frames above constructorOpt, including constructorOpt, will be omitted from the generated stack trace.

The constructorOpt argument is useful for hiding implementation details of error generation from the user. For instance:

function a() {
b();
}
function b() {
c();
}
function c() {
// Create an error without stack trace to avoid calculating the stack trace twice.
const { stackTraceLimit } = Error;
Error.stackTraceLimit = 0;
const error = new Error();
Error.stackTraceLimit = stackTraceLimit;
// Capture the stack trace above function b
Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
throw error;
}
a();

object

Function

void

Error.captureStackTrace


static prepareStackTrace(err, stackTraces): any

Defined in: node_modules/.pnpm/@[email protected]/node_modules/@types/node/globals.d.ts:56

Error

CallSite[]

any

https://v8.dev/docs/stack-trace-api#customizing-stack-traces

Error.prepareStackTrace