matrix-js-sdk
    Preparing search index...

    Class MatrixSafetyError

    This error is thrown when the homeserver refuses to handle an action due to a safety concern.

    Hierarchy (View Summary)

    Index
    errcode?: string
    error?: string
    event?: MatrixEvent
    expiry?: Date

    The date at which a request can be reattempted.

    harms: Set<string>

    The kinds of harms detected by the server.

    httpHeaders?: Headers
    httpStatus?: number
    url?: string
    • Returns number | null

      The recommended delay in milliseconds to wait before retrying the request that triggered this error, or null if no delay is recommended.

      Error if the recommended delay is an invalid value.

      safeGetRetryAfterMs for a version of this check that doesn't throw.

    • Check if this error was due to rate-limiting on the server side (and should therefore be retried after a delay).

      If this returns true, getRetryAfterMs can be called to retrieve the server-side recommendation for the retry period.

      Returns boolean

      Whether this error is due to rate-limiting.