List a linked mailbox's folders (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}/fetch-folders-for-email-provider/{providerId}

Inbox-connect plumbing: fetches the folders of a linked mailbox from the provider, saves them on the mailbox and returns them. Folder ids can be passed as folderIds when starting an import. An extraction-code user may only name a mailbox linked to their own code (404 otherwise).

Path parameters

  • caseId string Required
  • providerId string Required

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • data array[object] Required
      Hide data attributes Show data attributes object
      • id string
      • name string
      • isSystemFolder boolean
      • backgroundColor string | null
      • metadata object

        The folder as the provider returned it

    • statusCode number Required
    • timestamp string(date-time) Required
POST /email-data/{caseId}/fetch-folders-for-email-provider/{providerId}
curl \
 --request POST 'http://api.example.com/email-data/{caseId}/fetch-folders-for-email-provider/{providerId}' \
 --header "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": [
    {
      "id": "INBOX",
      "name": "Inbox",
      "isSystemFolder": true,
      "backgroundColor": "string",
      "metadata": {}
    }
  ],
  "statusCode": 200,
  "timestamp": "2026-01-15T10:15:00.000Z"
}