GmailToolkit 功能和配置的详细文档请前往 API reference.
设置
To use this toolkit, you will need to set up your credentials explained in the Gmail API docs. Once you’ve downloaded thecredentials.json file, you can start using the Gmail API.
安装
This toolkit lives in thelangchain-google-community package. We’ll need the gmail extra:
Instantiation
By default the toolkit reads the localcredentials.json file. You can also manually provide a Credentials object.
Customizing authentication
Behind the scenes, agoogleapi resource is created using the following methods.
you can manually build a googleapi resource for more auth control.
Tools
View available tools:Use within an agent
Below we show how to incorporate the toolkit in提供自然语言接口 agent. We will need a LLM or chat model:API 参考
所有GmailToolkit 功能和配置的详细文档请前往 API reference.
Connect these docs to Claude, VSCode, and more via MCP for real-time answers.

