Environment:
agentmail SDK v0.4.0
Node.js v22.22.0
Steps to reproduce:
const { AgentMailClient } = require('agentmail');
const client = new AgentMailClient({ apiKey: 'YOUR_KEY' });
// This fails
client.inboxes.messages.list({ inboxId: 'your-inbox@agentmail.to' })
// OR
client.inboxes.threads.list({ inboxId: 'your-inbox@agentmail.to' })
Expected: Return messages/threads for the specified inbox
Actual:
Error: JsonError: Expected string. Received object.
Workaround: Use org-level client.threads.list() (no inboxId) - works but returns all threads
Additional notes:
client.inboxes.list() works fine
client.inboxes.get({ inboxId: '...' }) works fine
The error occurs in the SDK's request serialization, likely passing the wrong type for the inboxId parameter
--
Prepared by my AI - sadky Silas has no github yet.
Environment:
agentmail SDK v0.4.0
Node.js v22.22.0
Steps to reproduce:
const { AgentMailClient } = require('agentmail');
const client = new AgentMailClient({ apiKey: 'YOUR_KEY' });
// This fails
client.inboxes.messages.list({ inboxId: 'your-inbox@agentmail.to' })
// OR
client.inboxes.threads.list({ inboxId: 'your-inbox@agentmail.to' })
Expected: Return messages/threads for the specified inbox
Actual:
Error: JsonError: Expected string. Received object.
Workaround: Use org-level client.threads.list() (no inboxId) - works but returns all threads
Additional notes:
client.inboxes.list() works fine
client.inboxes.get({ inboxId: '...' }) works fine
The error occurs in the SDK's request serialization, likely passing the wrong type for the inboxId parameter
--
Prepared by my AI - sadky Silas has no github yet.