Skip to content

Conversation

@jcscottiii
Copy link
Collaborator

This commit introduces API endpoints for managing user notification channels, addressing the initial scope outlined in issue #1844.

The following endpoints have been added under the /v1/users/me/ prefix, requiring user authentication:

  • GET /notification-channels: Lists all notification channels for the authenticated user.
  • GET /notification-channels/{channel_id}: Retrieves a single notification channel by its ID.
  • DELETE /notification-channels/{channel_id}: Deletes a specific notification channel.

Key changes include:

  • Updating the OpenAPI specification to define the new endpoints.
  • Implementing the corresponding HTTP handlers in backend/pkg/httpserver.
  • Adding the necessary methods to the WPTMetricsStorer interface and its mock implementation.
  • Including unit tests for the new handlers to ensure correctness and error handling.

This implementation lays the groundwork for future enhancements, such as creating and updating notification channels.

Fixes #1844

This commit introduces API endpoints for managing user notification
channels, addressing the initial scope outlined in issue #1844.

The following endpoints have been added under the `/v1/users/me/` prefix,
requiring user authentication:

- `GET /notification-channels`: Lists all notification channels for the authenticated user.
- `GET /notification-channels/{channel_id}`: Retrieves a single notification channel by its ID.
- `DELETE /notification-channels/{channel_id}`: Deletes a specific notification channel.

Key changes include:
- Updating the OpenAPI specification to define the new endpoints.
- Implementing the corresponding HTTP handlers in `backend/pkg/httpserver`.
- Adding the necessary methods to the `WPTMetricsStorer` interface and its mock implementation.
- Including unit tests for the new handlers to ensure correctness and error handling.

This implementation lays the groundwork for future enhancements, such as creating and updating notification channels.

Fixes #1844
@jcscottiii jcscottiii requested a review from jrobbins November 20, 2025 16:21
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.

[API] Implement CRUD Endpoints for Notification Channels

1 participant