RetryError
Namespace: Vercel.AI.Util
public sealed class RetryError : AiSdkError, ISerializable, IErrorMarkersRetries were exhausted or stopped.
Inheritance: object → Exception → AiSdkError
Implements: ISerializable, IErrorMarkers
Constructors
Section titled “Constructors”RetryError(string, RetryErrorReason, IReadOnlyList<object>)
Section titled “RetryError(string, RetryErrorReason, IReadOnlyList<object>)”public RetryError(string message, RetryErrorReason reason, IReadOnlyList<object> errors)Creates the error.
Parameters
| Name | Type | Description |
|---|---|---|
message |
string | |
reason |
RetryErrorReason | |
errors |
IReadOnlyList<object> |
Fields
Section titled “Fields”ErrorMarker
Section titled “ErrorMarker”public const string ErrorMarker = "vercel.ai.error.AI_RetryError"Marker for IsInstance(object).
Value: string
Properties
Section titled “Properties”Errors
Section titled “Errors”public IReadOnlyList<object> Errors { get; }Errors from each attempt, in order.
Value: IReadOnlyList<object>
LastError
Section titled “LastError”public object? LastError { get; }Last attempt’s error.
Value: object
Reason
Section titled “Reason”public RetryErrorReason Reason { get; }Why retrying stopped.
Value: RetryErrorReason
Methods
Section titled “Methods”IsInstance(object?)
Section titled “IsInstance(object?)”public static bool IsInstance(object? error)Returns whether <code class=“paramref”>error</code> carries this error’s marker.
Parameters
| Name | Type | Description |
|---|---|---|
error |
object |
Returns: bool
Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product