Gmail / warm

List Threads

List Gmail threads for the authenticated mailbox. Supports Gmail search syntax via q and returns thread ids for follow-up retrieval.

Quick Start

aweb inspect gmail.list_threads
aweb add gmail
aweb plan "use Gmail list threads in an agent workflow"
import Aweb, { Agent } from '@aweb/sdk';

const aweb = new Aweb({ apiKey: process.env.AWEB_API_KEY });
const agent = new Agent({ tools: aweb.tools });

agent.add('gmail');

const plan = await agent.plan('Use Gmail for this workflow');
const tool = await aweb.tools.inspect('gmail.list_threads');

console.log(plan.nextAction);
console.log(tool.inputSchema);

Tool Card

Tool idgmail.list_threads
ProviderGmail (gmail)
Tool namelist_threads
Activationwarm
Healthhealthy
Trust score1.00
Transportstreamable_http
Latencynot yet measured
Cost0

Requirements and Governance

Authoauth_2_1_pkce
Credentialsetup_required
Workspacerequired
Approvalnone
RiskREAD
Permissionshttps://www.googleapis.com/auth/gmail.readonly, https://www.googleapis.com/auth/gmail.compose, https://www.googleapis.com/auth/gmail.send, read
Credential setup/api/mcp-warehouse/credentials/gmail/init

Schemas

{
  "type": "object",
  "properties": {
    "q": {
      "type": "string",
      "description": "Optional Gmail search query (e.g. in:sent newer_than:7d to:user@example.com)."
    },
    "max_results": {
      "type": "integer",
      "description": "Maximum number of threads to return (default 25, max 100)."
    },
    "page_token": {
      "type": "string",
      "description": "Pagination token from a prior list_threads response."
    }
  },
  "additionalProperties": false
}

Examples

[
  {
    "objective": "Use Gmail list threads in an agent workflow.",
    "args": {
      "q": "<q>",
      "max_results": "<max_results>",
      "page_token": "<page_token>"
    }
  }
]
Back to MCP Tool Cards