Skip to content

google / Exports / IGoogleProviderOptions

Interface: IGoogleProviderOptions

Google AI Provider options

Hierarchy

Table of contents

Properties

Properties

apiKey

apiKey: string

Google AI API key

Defined in

google/src/types.ts:31


responseMimeType

Optional responseMimeType: "text/plain" | "application/json"

Response MIME type

  • 'text/plain': Plain text response (default)
  • 'application/json': JSON response format

Defined in

google/src/types.ts:38


responseSchema

Optional responseSchema: Record<string, TProviderOptionValue>

Response schema for JSON output (only used when responseMimeType is 'application/json')

Defined in

google/src/types.ts:43


executor

Optional executor: IExecutor

Optional executor for handling AI requests

When provided, the provider will delegate all chat operations to this executor instead of making direct API calls. This enables remote execution capabilities.

Example

typescript
import { LocalExecutor, RemoteExecutor } from '@robota-sdk/agent-core';

// Local execution (registers this provider)
const localExecutor = new LocalExecutor();
localExecutor.registerProvider('google', new GoogleProvider({ apiKey: 'AIza...' }));

// Remote execution
const remoteExecutor = new RemoteExecutor({
  serverUrl: 'https://api.robota.io',
  userApiKey: 'user-token-123',
});

const provider = new GoogleProvider({
  apiKey: 'placeholder', // Required for type safety but not used
  executor: remoteExecutor,
});

Defined in

google/src/types.ts:71

Released under the MIT License.