feat: Add Live Event Subscriptions API with feature flag - #2645
Open
jasonfill wants to merge 1 commit into
Open
Conversation
Read-only API endpoints for auditing live event subscriptions configured for a root account. Sensitive fields are masked in the response. flag=live_event_subscriptions_api test plan: - enable live_event_subscriptions_api feature flag - GET /api/v1/accounts/:id/live_event_subscriptions - verify sensitive fields are masked - verify sub-accounts return 400 - verify non-admins return 401
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.
Note
This could not be fully tested due to limited access to the live event service via the open source distribution.
Summary
Adds a read-only API for auditing Live Event subscriptions configured for a root account.
New endpoints
GET /api/v1/accounts/:account_id/live_event_subscriptions— list all subscriptionsGET /api/v1/accounts/:account_id/live_event_subscriptions/:id— show single subscriptionProxies to
Services::LiveEventsSubscriptionServiceand masks sensitive fields (AWS keys, secrets, credentials, tokens) via regex pattern matching. URLs have auth credentials and query params masked; base URLs are preserved.Gated behind
live_event_subscriptions_apifeature flag (hidden,allowed_onin dev/CI). Requiresmanage_data_servicespermission and root account context — sub-accounts return 400.Files changed
app/controllers/live_event_subscriptions_controller.rbconfig/feature_flags/00_standard.ymlconfig/routes.rbspec/apis/v1/live_event_subscriptions_api_spec.rbTest plan
live_event_subscriptions_apifeature flag on a root accountGET /api/v1/accounts/:id/live_event_subscriptions— verify subscriptions are returned with sensitive fields maskedGET /api/v1/accounts/:id/live_event_subscriptions/:id— verify single subscription with masked fields