google / Exports / IGoogleProviderOptions
Interface: IGoogleProviderOptions
Google AI Provider options
Hierarchy
↳
IGoogleProviderOptions
Table of contents
Properties
Properties
apiKey
• apiKey: string
Google AI API key
Defined in
responseMimeType
• Optional responseMimeType: "text/plain" | "application/json"
Response MIME type
- 'text/plain': Plain text response (default)
- 'application/json': JSON response format
Defined in
responseSchema
• Optional responseSchema: Record<string, TProviderOptionValue>
Response schema for JSON output (only used when responseMimeType is 'application/json')
Defined in
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,
});