Adds fields.upsert method#8
Merged
john-doherty merged 3 commits intomasterfrom Apr 29, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a fields.upsert method to the Node SDK to mirror the REST API bulk add/update behavior.
Changes:
- Add
client.fields.upsert(sheetId, fields)implemented asPUT /sheets/{sheetId}/fields. - Extend unit and e2e tests to cover the new upsert behavior and parameter validation.
- Update TypeScript definitions and README documentation to include
fields.upsert.
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/interface-spec.js | Updates interface method-count assertion for the new fields.upsert. |
| tests/fields-spec.js | Adds unit tests for fields.upsert request shape and parameter validation errors. |
| tests/e2e/03-fields-e2e-spec.js | Adds an e2e test to upsert fields and verify they appear in fields.list, then cleans up. |
| index.js | Implements fields.upsert in the SDK fields namespace. |
| index.d.ts | Exposes fields.upsert in the public TypeScript API. |
| README.md | Documents fields.upsert usage and admin permission note. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds
fields.upsertmethod to match the REST API PR, which allows fields to be added/updated in bulk.