When an agent tries to sign up or log into a service that sends an email OTP, the options are terrible. You either dump the full email HTML into your LLM context (slow, expensive, fragile) or you write a polling loop that constantly checks for new emails.
AgentMailr solves this with long-polling. You create a named inbox for your agent, then call waitForOtp() which hangs the HTTP request open until the email arrives and returns just the extracted code.
const inbox = await client.createInbox({ "my-agent" }) // my-agent@agentmailr.com
const otp = await inbox.waitForOtp({ timeout: 60000 }) // returns "847291" automatically
Supports 4-digit, 6-digit, alphanumeric codes, and magic links.
Built this because I needed it. Would love feedback especially from people running agents at scale.