Start linking a mailbox (internal)

Add MCP server to your AI tool

Allow AI tools and LLMs to interact with the API documentation portal through MCP.

MCP server URL

https://docs.usehearsay.com/mcp

Standard setup for AI tools providing an mcp.json file

mcp.json
{
  "integrations MCP server": {
    "url": "https://docs.usehearsay.com/mcp"
  }
}

Close
POST /email-data/{caseId}/create-oauth-url

Inbox-connect plumbing: returns the email provider's OAuth sign-in URL for linking a mailbox to the case. The caller opens it and sends the returned code to add-email-provider.

Path parameters

  • caseId string Required
application/json

Body Required

  • redirectUri string Required
  • provider string Required

    Values are google, yahoo, imap, microsoft, icloud, or ews.

Responses

  • 201 application/json
    Hide response attributes Show response attributes object
    • data object Required
      Hide data attribute Show data attribute object
      • url string Required
    • statusCode number Required
    • timestamp string(date-time) Required
POST /email-data/{caseId}/create-oauth-url
curl \
 --request POST 'http://api.example.com/email-data/{caseId}/create-oauth-url' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --data '{
  "redirectUri": "string",
  "provider": "google"
}'
Request examples
{
  "redirectUri": "string",
  "provider": "google"
}
Response examples (201)
{
  "data": {
    "url": "https://accounts.example.com/oauth/authorize?client_id=abc123&state=xyz"
  },
  "statusCode": 201,
  "timestamp": "2026-01-15T10:15:00.000Z"
}