Skip to content

Mulla759/GWSforDummies / .claude/skills/gws-gmail-users-threads-list

gws-gmail-users-threads-list

Verified

Gmail: List threads in a user's mailbox with optional filtering.

gmail users threads list

List threads in a user's mailbox. Returns thread IDs and snippet previews. Each thread groups related messages in a conversation.

Usage

gws gmail users threads list --params '<JSON>'

Parameters (--params JSON)

ParameterRequiredDefaultDescription
userId✓—The user's email address or "me" for the authenticated user
maxResults—100Maximum number of threads to return (1–500)
q——Gmail search query, same syntax as the Gmail search box (e.g. "is:unread from:alice")
labelIds——Array of label IDs to filter by. Only threads with all specified labels are returned
pageToken——Token for the next page of results (from a previous response's nextPageToken)
includeSpamTrash—falseInclude threads from SPAM and TRASH in results

Global Flags

FlagDescription
--formatOutput format: json (default), table, yaml, csv
--page-allAuto-paginate through all results, outputting one JSON line per page
--page-limitMaximum number of pages to fetch when using --page-all (default: 10)
--dry-runShow the request that would be sent without executing it

Examples

# List the 5 most recent threads
gws gmail users threads list --params '{"userId": "me", "maxResults": 5}'

# Search for threads from a specific sender
gws gmail users threads list --params '{"userId": "me", "q": "from:notifications@github.com"}'

# List unread inbox threads
gws gmail users threads list --params '{"userId": "me", "q": "is:unread", "labelIds": ["INBOX"], "maxResults": 10}'

Response Shape

{
  "threads": [
    { "id": "19ea3ab6ef5d5f9f", "snippet": "Your order has been...", "historyId": "50817087" },
    { "id": "19ea336ce5191c04", "snippet": "Reminder: Content older...", "historyId": "50816320" }
  ],
  "nextPageToken": "...",
  "resultSizeEstimate": 42
}
  • threads[].id — Use with gws gmail users threads get to fetch the full conversation.
  • threads[].snippet — Short preview of the most recent message.
  • nextPageToken — Pass as pageToken in the next request to get the next page.

Tips

  • Threads group related messages (replies, forwards) into a single conversation.
  • The q parameter supports the full Gmail search syntax.
  • Use threads instead of messages when you need conversation context (e.g., relationship analysis across a reply chain).

See Also

slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall