Email

Use the Mail API and AI agents

Create scoped mailbox keys or connect an AI agent for controlled mail automation.

VPSLY domain Mail API key management
VPSLY domain Mail API key management · Fictional VPSLY demonstration data.

Mail API keys let an application send and retrieve mail for one mailbox or a known domain mailbox. Agent URLs expose a controlled MCP interface to compatible AI tools.

Step by step

  1. Create a Mail API key

    Open the domain Mail API tab, choose the mailbox scope, name the key and select read or write capabilities.

  2. Store the secret

    Copy the key when it is shown and store it in the application's secret manager. Revoke keys that are no longer needed.

  3. Call the mail surface

    Use /api/mail/v1 endpoints for mailbox discovery, folders, messages, attachments and sending. The key only works on the Mail API surface.

  4. Connect an agent

    Create or copy an agent URL from the Agents tab and configure it in a compatible AI client. The URL is scoped to the selected mailbox.

Good to know

  • Mail keys are separate from general personal access tokens.
  • Use the public Mail API documentation for request and response examples.

Hosting through VPSLY

A question about your hosting?

Browse the guides or contact us directly. We’ll help you find the right setup.