Skip to main content

Search Gmail Threads

Curated Reference

This page is maintained from curated documentation data.

GETgoogle.gmail_search_threads

Search Gmail threads by query syntax and timeframe.

Request Body

{
"jsonrpc": "2.0",
"id": "google-gmail-search-threads-example",
"method": "tools/call",
"params": {
"name": "google.gmail_search_threads",
"arguments": {
"query": "is:unread newer_than:2d subject:(support OR billing)",
"limit": 20
}
}
}

Arguments Schema

{
"type": "object",
"properties": {
"query": {
"type": "string"
},
"limit": {
"type": "number",
"minimum": 1,
"maximum": 100
}
},
"additionalProperties": false
}

Code Examples

curl -X POST 'https://madpanda3d.com/lab/mad-mcps/portal/api/mcp' \
-H 'Authorization: Bearer mad_live_***' \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"id": "google-gmail-search-threads-example",
"method": "tools/call",
"params": {
"name": "google.gmail_search_threads",
"arguments": {
"query": "is:unread newer_than:2d subject:(support OR billing)",
"limit": 20
}
}
}'

Example Responses

{
"ok": true,
"threads": [
{
"id": "thread_91",
"subject": "Billing issue",
"snippet": "Need help with invoice..."
}
]
}