feat(notebooks): add cells append command for cell-level operations#64
Closed
majorgreys wants to merge 1 commit intomainfrom
Closed
feat(notebooks): add cells append command for cell-level operations#64majorgreys wants to merge 1 commit intomainfrom
majorgreys wants to merge 1 commit intomainfrom
Conversation
Add `notebooks cells append` subcommand that appends individual cells
to an existing notebook using the internal /api/v1/notebooks/{id}/cells
endpoint, matching the Datadog MCP server's cell-level operations.
Supports three cell types via simplified JSON format:
- markdown: text content with Markdown formatting
- metric: timeseries graphs with Datadog metrics query language
- logs: log stream widgets with Datadog logs query language
Cells are validated before any API calls to prevent partial failures.
Error messages distinguish between full and partial append failures
when sending multiple cells.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4168ab9 to
b91f052
Compare
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.
Summary
notebooks cells appendsubcommand that appends individual cells to an existing notebookChanges
cmd/notebooks.go: Addcellssubcommand group withappendcommand, simplified cell types, cell builders for markdown/metric/logs, time parser, and append loop with partial failure handlingcmd/notebooks_test.go: Add 15 new tests covering command structure, cell building, time parsing, validation errors, and runtime behaviordocs/COMMANDS.md: Update notebooks entry to reflect new capabilitiesUsage
Design Notes
Test plan
go build ./...passesgo test ./cmd/ -run "TestNotebooks|TestBuildCell|TestParseCellTimes" -v— 25 tests passgo test ./... -race— all tests passgo vet ./...— clean🤖 Generated with Claude Code