getInbox
Retrieve a specific inbox by ID using AgentMail’s API, enabling AI agents to access, manage, and interact with isolated email environments efficiently.
Instructions
Get inbox by ID
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| inbox_id | Yes |
Implementation Reference
- node/src/functions.ts:19-22 (handler)Node.js handler function that implements the getInbox tool by calling client.inboxes.get with the inbox_id and any additional options.export async function getInbox(client: AgentMailClient, args: Args) { const { inbox_id, ...options } = args return client.inboxes.get(inbox_id, options) }
- Python handler function that implements the get_inbox tool by calling client.inboxes.get with unpacked kwargs.def get_inbox(client: AgentMail, kwargs: Kwargs): return client.inboxes.get(**kwargs)
- node/src/tools.ts:42-47 (registration)Node.js registration of the get_inbox tool in the tools array, linking schema and handler function.{ name: 'get_inbox', description: 'Get inbox', params_schema: GetInboxParams, func: getInbox, },
- python/src/agentmail_toolkit/tools.py:45-50 (registration)Python registration of the get_inbox tool in the tools list, linking schema and handler function.Tool( name="get_inbox", description="Get inbox", params_schema=GetInboxParams, func=get_inbox, ),
- node/src/schemas.ts:13-15 (schema)Node.js Zod schema defining the input parameters for the get_inbox tool, requiring an inbox_id.export const GetInboxParams = z.object({ inbox_id: InboxIdSchema, })