Fix README: prompt takes ImageContent[], not Attachment[]

This commit is contained in:
Mario Zechner 2025-12-28 09:31:41 +01:00
parent 256d9a26bb
commit b6d9442916

View file

@ -152,19 +152,14 @@ agent.queueMessage({
When queued messages are detected after a tool call, remaining tool calls are skipped with error results. When queued messages are detected after a tool call, remaining tool calls are skipped with error results.
## Attachments ## Images
User messages can include attachments (images, documents): User messages can include images:
```typescript ```typescript
await agent.prompt('What is in this image?', [{ await agent.prompt('What is in this image?', [
id: 'img1', { type: 'image', data: base64ImageData, mimeType: 'image/jpeg' }
type: 'image', ]);
fileName: 'photo.jpg',
mimeType: 'image/jpeg',
size: 102400,
content: base64ImageData // base64 without data URL prefix
}]);
``` ```
## Proxy Usage ## Proxy Usage