salt-sdk - v0.0.45
    Preparing search index...

    Class KeyshareBackupUnavailableErrorSealed

    Thrown when Salt cannot back up a new account's keyshare. The backup is an on-chain write paid for by Salt, and Salt is currently unable to pay for it. Nothing on the caller's side can fix this: contact Salt, then create the account again.

    The backend reports it as a 500 with errorCode KEYSHARE_BACKUP_UNAVAILABLE. This is a subclass of ApiError, so existing catch (e) { if (e instanceof ApiError) ... } handlers keep working.

    import { KeyshareBackupUnavailableError } from 'salt-sdk';

    try {
    const { account } = await (await salt.createAccount({ ... })).wait();
    } catch (err) {
    if (err instanceof KeyshareBackupUnavailableError) {
    console.error('Account backup is unavailable, please contact Salt');
    } else {
    throw err;
    }
    }

    Hierarchy (View Summary)

    • ApiError
      • KeyshareBackupUnavailableError
    Index
    body?: unknown

    The full parsed JSON response body, when available.

    code?: string

    Application error code from the response body, if present. E.g. "INSUFFICIENT_FUNDS", "CALL_EXCEPTION".

    headers?: Headers

    Raw response headers, when available — e.g. to read PAYMENT-REQUIRED off a 402.

    message: string
    method?: string

    The HTTP method (e.g. GET, POST), when available.

    name: string
    stack?: string
    status: number

    HTTP status code (e.g. 500, 404).

    url?: string

    The request URL, when available.