Types Reference
Complete TypeScript type definitions for the AgenticWork SDK.
Message Types
type MessageRole = 'system' | 'user' | 'assistant' | 'tool';
interface Message {
role: MessageRole;
content: string | ContentPart[];
name?: string;
toolCalls?: ToolCall[];
toolCallId?: string;
}
interface TextContent {
type: 'text';
text: string;
}
interface ImageContent {
type: 'image';
source: {
type: 'base64' | 'url';
mediaType?: string;
data?: string;
url?: string;
};
}
type ContentPart = TextContent | ImageContent;Tool Types
Completion Types
Streaming Types
Rich Streaming Events
For CLI and UI applications:
Provider Types
Agent Types
Platform Types
AgentiCode Config Types
Importing Types
Last updated