list_labels
Retrieve all Gmail labels and their IDs so you can map label names before modifying message labels. Read-only; includes system and user labels.
Instructions
List all labels in the account as {labels:[{id,name,type}]}, covering system labels (INBOX, UNREAD, STARRED, SPAM, TRASH) and user labels. Use it to map label names to the IDs modify_message_labels needs. Read-only; does not create labels.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"account": "<account>"
},
"name": "list_labels"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| account | Yes | Account alias from list_accounts; selects which mailbox to use. |