Files
AutoGPT/docs
Toran Bruce Richards e50366726c feat(blocks/gmail): add Gmail thread blocks (#9965)
This PR adds two new Gmail integration blocks—**Gmail Get Thread** and
**Gmail Reply**—to the platform, enhancing threaded email workflows. Key
changes include:

- **GmailGetThreadBlock**:  
- New block that retrieves an entire Gmail thread by `threadId`, with an
option to include or exclude messages from Spam and Trash.
- Supports use cases like fetching all messages in a conversation to
check for responses.

- **GmailReplyBlock**:  
- New block that sends a reply within an existing Gmail thread,
maintaining the thread context.
- Accepts detailed input fields including recipients, CC, BCC, subject,
body, and attachments.
- Ensures replies are properly associated with their parent message and
thread.

- **Enhancements to existing Gmail blocks**:  
- The `Email` model and related outputs now include a `threadId` field.
  - Updated test data and mock data to support threaded operations.
  - Expanded OAuth scopes for actions requiring thread metadata.

- **Documentation updates**:  
- Added documentation for the new Gmail blocks in both the general block
listing and the detailed Gmail block docs.
  - Clarified that the `Email` output now includes the `threadId`.

These updates enable more advanced and context-aware Gmail automations,
such as fetching full conversations and replying inline, supporting
richer communication workflows with Gmail.

## Checklist 📋

### For code changes

- [x] I have clearly listed my changes in the PR description
- [x] I have made a test plan
- [x] I have tested my changes according to the test plan:
  - [x] Try all the gmail blocks
  - [x] Send an email reply based on a thread from the get thread block

---------

Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co>
2025-07-17 20:11:31 +00:00
..