flag-message
Flag a single message in Apple Mail using its ID, optionally assigning a color from the palette (red, orange, yellow, green, blue, purple, gray).
Instructions
Use when: flagging a single message (by id), optionally with a color (red/orange/yellow/green/blue/purple/gray). Returns: a confirmation that the message was flagged (and the color, when applied). Do not use when: flagging several at once (use batch-flag-messages) or removing a flag (use unflag-message). Get the id from search-messages or list-messages first. Note: flag colors are a Mail.app feature applied via AppleScript; for an IMAP-routed id the flag is set but the color is not applied (IMAP flags are colorless).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| color | No | Optional flag color (Apple Mail palette: red, orange, yellow, green, blue, purple, gray — 'grey' accepted). Omit for Mail's default flag. Colors are applied via Mail.app (AppleScript); for an IMAP-routed message id the flag is set but the color is not applied (IMAP flags are colorless). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | ||
| ok | No | ||
| color | No | ||
| colorApplied | No |