Class in Errors · JavaScript & TypeScript
A cleanup preview or deletion failed, with selected IDs and batch progress where available
Preview never deletes. Cleanup can fail after earlier batches received successful responses. The submitted field describes only those earlier responses. The terminal field identifies the failed or uncertain request when reached. Its message and details contain no message bodies or criteria, and it proves neither individual deletion nor safe replay. A filter that threw keeps its thrown value as cause, and a failed history read or batch request keeps its operation error as cause. Cancellation in the default API is returned separately as Cancelled. Native interruption and unexpected defects remain outside this error
class MessageCleanupError extends FluxerlyErrorclass MessageCleanupError
extends FluxerlyErrorConstructor#
Record an expected preview or cleanup failure and the submission knowledge available at that point
Optional validation and Fluxer details default to null. Construction performs no requests, deletion or recovery
new MessageCleanupError(
options: {
readonly apiError?: ApiErrorDetail | null
readonly cause?: unknown
readonly inputValidation?: InputValidationDetail | null
readonly outcome: MessageCleanupOutcome
readonly phase: "cleanup" | "preview"
readonly providerCode?: string | null
readonly reason: MessageCleanupErrorReason
readonly responseField?: string | null
readonly retryAfterMs: number | null
readonly scannedCount: number
readonly selectedMessageIds: readonly string[]
readonly status: number | null
readonly submittedBatches: readonly MessageCleanupBatch[]
readonly terminalBatchIds: readonly string[] | null
}
): MessageCleanupErrornew MessageCleanupError(
options: {
readonly apiError?:
| ApiErrorDetail | null
readonly cause?: unknown
readonly inputValidation?:
| InputValidationDetail
| null
readonly outcome:
MessageCleanupOutcome
readonly phase:
| "cleanup" | "preview"
readonly providerCode?:
| string | null
readonly reason:
MessageCleanupErrorReason
readonly responseField?:
| string | null
readonly retryAfterMs:
| number | null
readonly scannedCount: number
readonly selectedMessageIds:
readonly string[]
readonly status: number | null
readonly submittedBatches: readonly MessageCleanupBatch[]
readonly terminalBatchIds:
| readonly string[]
| null
}
): MessageCleanupErrorParameters
options-
apioptionalError -
ApiErrorDetail | null causeoptional-
unknown inputoptionalValidation -
InputValidationDetail | null outcome-
MessageCleanupOutcome phase-
"cleanup" | "preview" provideroptionalCode -
Fluxer error code that this SDK version does not recognize, recorded as
detailsand named in the message.provider Code Ignored when
apiis present or the code does not have the shape of a Fluxer codeError string | null reason-
MessageCleanupErrorReason responseoptionalField -
Response field path or named check that failed, recorded as
detailsfor reason response.response Field string | null retryAfter Ms -
number | null scannedCount -
number selectedMessage Ids -
readonly string[] status-
number | null submittedBatches -
readonly MessageCleanupBatch[] terminalBatch Ids -
readonly string[] | null
Properties#
_tag#
Literal error tag for identifying Message
readonly _tag: "MessageCleanupError"apiError #
Safe Fluxer rejection detail for the failed stage, or null when unavailable
readonly apiError: ApiErrorDetail | nullreadonly apiError:
| ApiErrorDetail | nullinputValidation #
Safe local validation detail, copied and frozen, or null for other failures
readonly inputValidation: InputValidationDetail | nullreadonly inputValidation:
| InputValidationDetail | nulloutcome#
What is known about dispatch at the failed stage, not about the earlier successful batches
readonly outcome: MessageCleanupOutcomephase#
Which stage failed
The preview phase never deletes, while cleanup can fail after earlier batch submissions
readonly phase: "cleanup" | "preview"readonly phase:
| "cleanup" | "preview"reason#
Expected failure classification
The failed message operation or thrown filter value is available through cause
readonly reason: MessageCleanupErrorReasonretryAfterMs #
Fluxer's retry delay in milliseconds, or null
This delay does not establish that a repeat request is safe
readonly retryAfterMs: number | nullreadonly retryAfterMs:
| number | nullscannedCount #
Messages inspected before preview failed, or the completed preview's scan count when cleanup failed
readonly scannedCount: numberselectedMessageIds #
Selected message IDs known at failure time, without message bodies or filter details
readonly selectedMessageIds: readonly string[]status#
HTTP status at the failed stage, or null when unavailable
readonly status: number | nullsubmittedBatches #
Earlier batch requests with successful HTTP responses, not confirmed individual deletions
readonly submittedBatches: readonly MessageCleanupBatch[]terminalBatchIds #
Failed or uncertain batch's IDs when a batch request was reached, otherwise null
readonly terminalBatchIds: readonly string[] | nullreadonly terminalBatchIds:
| readonly string[]
| nullInherited#
Inherited from Fluxerly: code, details, hint, to