Skip to content

NoSuchProviderReferenceError

Namespace: Vercel.AI.ProviderUtils

public sealed class NoSuchProviderReferenceError : AiSdkError, ISerializable, IErrorMarkers

A provider reference has no entry for the requested provider. Maps to NoSuchProviderReferenceError.

Inheritance: object → Exception → AiSdkError

Implements: ISerializable, IErrorMarkers

View source

NoSuchProviderReferenceError(string, IReadOnlyDictionary<string, string>, string?)

Section titled “NoSuchProviderReferenceError(string, IReadOnlyDictionary<string, string>, string?)”
public NoSuchProviderReferenceError(string provider, IReadOnlyDictionary<string, string> reference, string? message = null)

Creates the error.

Parameters

Name Type Description
provider string
reference IReadOnlyDictionary<string, string>
message string

View source

public const string ErrorMarker = "vercel.ai.error.AI_NoSuchProviderReferenceError"

Marker for IsInstance(object).

Value: string

View source

public string Provider { get; }

Requested provider.

Value: string

View source

public IReadOnlyDictionary<string, string> Reference { get; }

The reference that was searched.

Value: IReadOnlyDictionary<string, string>

View source

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

View source

Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product