FetchErrors
Namespace: Vercel.AI.ProviderUtils
public static class FetchErrorsTurns transport failures into retryable ApiCallErrors. Maps to handleFetchError.
Inheritance: object
Methods
Section titled “Methods”HandleFetchError(Exception, string, object)
Section titled “HandleFetchError(Exception, string, object)”public static Exception HandleFetchError(Exception error, string url, object requestBodyValues)Returns abort errors unchanged. An HttpRequestException with an inner cause, or any error caused by a connection-level SocketException, becomes a retryable ApiCallError. Other errors are returned unchanged.
Parameters
| Name | Type | Description |
|---|---|---|
error |
Exception | |
url |
string | |
requestBodyValues |
object |
Returns: Exception
Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product