Docsgeneric
recipe-email-drive-link
Share a Google Drive file and email the link with a message to recipients.
googleworkspace/clidocs.google.com
Install
Use with your agent
Install the recipe-email-drive-link skill, then use it as build context. Run: npx skills add https://github.com/googleworkspace/cli --skill recipe-email-drive-link. Then read the installed skill.md and follow its guidance to build or refactor my project.
Email a Google Drive File Link
PREREQUISITE: Load the following skills to execute this recipe:
gws-drive,gws-gmail
Share a Google Drive file and email the link with a message to recipients.
Steps
- Find the file:
gws drive files list --params '{"q": "name = '\''Quarterly Report'\''"}' - Share the file:
gws drive permissions create --params '{"fileId": "FILE_ID"}' --json '{"role": "reader", "type": "user", "emailAddress": "[email protected]"}' - Email the link:
gws gmail +send --to [email protected] --subject 'Quarterly Report' --body 'Hi, please find the report here: https://docs.google.com/document/d/FILE_ID'