GoogleVertexEndpoints
Namespace: Vercel.AI.Google
public static class GoogleVertexEndpointsVertex host and URL construction. Locations are single DNS labels so they cannot rewrite the host.
Inheritance: object
Fields
Section titled “Fields”ExpressModeBaseUrl
Section titled “ExpressModeBaseUrl”public const string ExpressModeBaseUrl = "https://aiplatform.googleapis.com/v1/publishers/google"Express Mode origin used when an API key is supplied.
Value: string
Methods
Section titled “Methods”AnthropicBaseUrl(string?, string?, string?)
Section titled “AnthropicBaseUrl(string?, string?, string?)”public static string AnthropicBaseUrl(string? project, string? location, string? baseUrl)Anthropic on Vertex publisher URL.
Parameters
| Name | Type | Description |
|---|---|---|
project |
string | |
location |
string | |
baseUrl |
string |
Returns: string
GeminiBaseUrl(string, string, string?, bool, bool)
Section titled “GeminiBaseUrl(string, string, string?, bool, bool)”public static string GeminiBaseUrl(string project, string location, string? baseUrl, bool expressMode, bool endpointModel)Publisher base URL for Gemini on Vertex. Tuned endpoints/ ids omit /publishers/google.
Parameters
| Name | Type | Description |
|---|---|---|
project |
string | |
location |
string | |
baseUrl |
string | |
expressMode |
bool | |
endpointModel |
bool |
Returns: string
Host(string)
Section titled “Host(string)”public static string Host(string location)Returns the Vertex AI host for <code class=“paramref”>location</code>.
global uses the unprefixed host. eu and us use the multi-region REP host.
Parameters
| Name | Type | Description |
|---|---|---|
location |
string |
Returns: string
IsEndpointModel(string)
Section titled “IsEndpointModel(string)”public static bool IsEndpointModel(string modelId)True when the model id addresses a deployed endpoint.
Parameters
| Name | Type | Description |
|---|---|---|
modelId |
string |
Returns: bool
MaasBaseUrl(string, string?, string?)
Section titled “MaasBaseUrl(string, string?, string?)”public static string MaasBaseUrl(string project, string? location, string? baseUrl)OpenAI-compatible MaaS URL. An empty base URL is rebuilt from the project and location.
Parameters
| Name | Type | Description |
|---|---|---|
project |
string | |
location |
string | |
baseUrl |
string |
Returns: string
RecognizeUrl(string, string)
Section titled “RecognizeUrl(string, string)”public static string RecognizeUrl(string project, string location)Cloud Speech-to-Text recognize URL.
Parameters
| Name | Type | Description |
|---|---|---|
project |
string | |
location |
string |
Returns: string
RequireLabel(string, string)
Section titled “RequireLabel(string, string)”public static string RequireLabel(string location, string name)Rejects a location that is not one DNS label.
Parameters
| Name | Type | Description |
|---|---|---|
location |
string | |
name |
string |
Returns: string
SpeechHost(string)
Section titled “SpeechHost(string)”public static string SpeechHost(string location)Speech-to-Text host. global is speech.googleapis.com.
Parameters
| Name | Type | Description |
|---|---|---|
location |
string |
Returns: string
XaiBaseUrl(string, string?, string?)
Section titled “XaiBaseUrl(string, string?, string?)”public static string XaiBaseUrl(string project, string? location, string? baseUrl)xAI on Vertex always uses the global AI Platform host.
Parameters
| Name | Type | Description |
|---|---|---|
project |
string | |
location |
string | |
baseUrl |
string |
Returns: string
Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product