Repository navigation
feat(tool/looker): add data app extension, dashboard, and layout tools - #4411
brettguenther wants to merge 4 commits into
Conversation
…ard element support
Add native support for Looker Data App Extensions and full-bleed extension
dashboard element mounting and updating.
1. Implement looker-create-data-app-extension tool:
- Target POST /api/4.0/data_app_extension via Looker SDK transport.
- Enforce dashboard-tile-only mount points and sandboxed core API entitlements.
- Validate label, code (up to 5 MB), and auto-generate or validate unique system name.
- Inject window.__lookerDataAppMeta with publishedAt UTC timestamp.
2. Implement looker-update-data-app-extension tool:
- Target PATCH /api/4.0/data_app_extension/:data_app_extension_id via Looker SDK transport.
- Update JavaScript ES module source code in-place on existing tiles.
- Support optional dashboard_id for contextual edit authorization in shared folders.
- Validate id formatting and prevent path traversal.
3. Enhance add_dashboard_element and update_dashboard_element:
- Add type: "extension" and extension_id parameters.
- Automatically infer type: "extension" when extension_id is present.
- Bypass query creation and route extension_id directly to WriteDashboardElement.
- Default title_hidden to true for extension tiles.
- Automatically configure host dashboard for full-bleed rendering (layout type="extension"
and zeroed margins/padding/header via best-effort PATCH).
4. Prebuilt configs, integration tests, and documentation:
- Register tools in looker.yaml prebuilt config under looker-dev and looker_tools groups.
- Add comprehensive unit tests and integration test parameter manifests.
- Add Hugo documentation guides with strict H2 ordering and CI validation.
…ools for atomic full-bleed parity - Add looker-update-dashboard tool for updating dashboard containers, titles, descriptions, and full-bleed appearance settings (show_dashboard_header, margins, tile spacing, shadows) - Add looker-update-dashboard-layout tool for updating dashboard layouts, switching layout types (extension vs newspaper), active states, and labels - Remove implicit ConfigureExtensionDashboard side-effects from add_dashboard_element and update_dashboard_element in favor of explicit atomic tools - Register both tools across prebuilt configs, imports, annotations tests, and integration test suites - Document the 5-step atomic publishing lifecycle in documentation
There was a problem hiding this comment.
Code Review
This pull request introduces new Looker tools (create_data_app_extension, update_data_app_extension, update_dashboard, and update_dashboard_layout) and updates existing ones (add_dashboard_element and update_dashboard_element) to support Looker Data Applications and Data App Extensions. Feedback on the changes includes removing a redundant wde.Title assignment in lookercommon.go, validating that at least one updatable field is provided in lookerupdatedashboardlayout.go before invoking the update API, and removing the enum field from the expected MCP manifest schema in looker_integration_test.go as allowed values are not emitted in the generated schema.
|
/gcbrun |
|
The integration test failed. |
…gration test manifest
|
/gcbrun |
Description
Adds native Looker MCP tools and dashboard element support for building, deploying, and managing Looker Data Applications and full-bleed dashboard containers:
create_data_app_extension&update_data_app_extension: Targets Looker's /api/4.0/data_app_extension endpoints with server-enforced dashboard-tile mount points, sandboxed entitlements, and automatic publishedAt metadata stamping via EnsureDataAppMeta.update_dashboard: Updates Looker dashboards (PATCH /api/4.0/dashboards/:id), enabling full-bleed container styling (show_dashboard_header: false, margins 0, spacing 0, shadows false), titles, and descriptions.update_dashboard_layout: Updates dashboard layouts (PATCH /api/4.0/dashboard_layouts/:id), enabling switching layout type to "extension" (frameless 100% viewport) and toggling active tabs.add_dashboard_element&update_dashboard_element: Adds type: "extension" and extension_id support (db:: / app::) with automatic type inference, query generation bypass, and default title_hidden: true.PR Checklist
CONTRIBUTING.md
bug/issue
before writing your code! That way we can discuss the change, evaluate
designs, and agree on the general idea
review
!if this involve a breaking change🛠️ Fixes #4410