docs(gws-docs): add COOKBOOK.md with hand-written recipes#712
docs(gws-docs): add COOKBOOK.md with hand-written recipes#712nuthalapativarun wants to merge 4 commits intogoogleworkspace:mainfrom
Conversation
Adds the first cookbook-pattern file for gws-docs. Covers: - Tab CRUD: read, create, write to a specific tab, rename, delete - Formatted content insertion: headings, bold/italic, bulleted lists - Valid batchUpdate request types reference table - +write helper limitations and workarounds Closes googleworkspace#420
🦋 Changeset detectedLatest commit: d5e2d36 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a new documentation pattern by adding a hand-written cookbook for Google Docs. The goal is to provide developers with clear, actionable examples for complex API interactions that fall outside the scope of auto-generated documentation, thereby improving the developer experience for advanced use cases. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces a new COOKBOOK.md guide for the Google Workspace CLI, detailing common Google Docs patterns such as tab CRUD operations, formatted content insertion, and limitations of the +write helper. Review feedback correctly identified that the examples for text styling and bulleted lists were incomplete; they lacked the necessary gws command context and the requests wrapper required for valid batchUpdate API calls.
… commands Both examples were missing the gws CLI context and the required 'requests' wrapper that batchUpdate expects. Now show complete, copy-pasteable commands consistent with the other recipes.
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces a new COOKBOOK.md file for the gws-docs skill, providing practical recipes for tab CRUD operations, formatted content insertion, and a reference for batchUpdate request types. The review feedback correctly identifies schema inaccuracies in the addDocumentTab and updateDocumentTab examples, where incorrect field names and structures would lead to API request failures.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces a new COOKBOOK.md guide for Google Docs, providing practical recipes for tab management, formatted content insertion, and advanced batchUpdate operations. It also includes a changeset for the @googleworkspace/cli package. I have no feedback to provide.
Summary
Closes #420
SKILL.mdfiles are auto-generated and cover API method listings. Complex services like Google Docs have non-obvious patterns (tab targeting, the insert-then-style sequence, whichbatchUpdaterequest types actually exist) that require hand-written guidance.This PR introduces
skills/gws-docs/COOKBOOK.mdas a proof-of-concept for the cookbook pattern proposed in #420. The file is safe fromgws generate-skillsregeneration and covers:includeTabsContent, create viaaddDocumentTab(notcreateTab), write to a specific tab withtabIdinlocation, rename, deletebatchUpdaterequest types — reference table of every supported request type+writelimitations — plain-text/append-only constraints with workarounds pointing to the raw APIChanges
skills/gws-docs/COOKBOOK.md— new hand-written recipe file.changeset/docs-gws-docs-cookbook.md— patch changeset