Skip to content

Refactor route configuration to remove dashboardId from widget generation endpoint#1641

Merged
Artuomka merged 2 commits intomainfrom
backend_remove_dashboard_id_from_generate_panel_position
Feb 27, 2026
Merged

Refactor route configuration to remove dashboardId from widget generation endpoint#1641
Artuomka merged 2 commits intomainfrom
backend_remove_dashboard_id_from_generate_panel_position

Conversation

@Artuomka
Copy link
Collaborator

No description provided.

Copilot AI review requested due to automatic review settings February 27, 2026 09:03
@Artuomka Artuomka enabled auto-merge February 27, 2026 09:04
@Artuomka Artuomka disabled auto-merge February 27, 2026 09:04
@Artuomka Artuomka merged commit 971c23f into main Feb 27, 2026
14 of 16 checks passed
@Artuomka Artuomka deleted the backend_remove_dashboard_id_from_generate_panel_position branch February 27, 2026 09:04
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request refactors the route configuration for the AI widget generation endpoint by removing the dashboardId parameter from the URL path. The change aligns the route structure with the endpoint's actual functionality - generating widget configurations without persisting them to a specific dashboard.

Changes:

  • Updated the authentication middleware route configuration to change /dashboard/:dashboardId/widget/generate/:connectionId to /widget/generate/:connectionId

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

.forRoutes(
{ path: '/dashboard/:dashboardId/widget/:connectionId', method: RequestMethod.POST },
{ path: '/dashboard/:dashboardId/widget/generate/:connectionId', method: RequestMethod.POST },
{ path: '/widget/generate/:connectionId', method: RequestMethod.POST },
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The route path has been changed from /dashboard/:dashboardId/widget/generate/:connectionId to /widget/generate/:connectionId, but the frontend code at frontend/src/app/services/dashboards.service.ts:149 still references the old path. This will cause API calls from the frontend to fail with 404 errors. The frontend code must be updated to use the new route path /widget/generate/${connectionId} instead of /dashboard/${dashboardId}/widget/generate/${connectionId}.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants