Skip to content

Commit df07690

Browse files
committed
ref(api): use token operationIds + summary for preprod/monitors/sentry_apps/notifications/seer/feedback
operationId->token migration, batch 3 of 3 (35 ops). Sentence -> summary=, operation_id -> camelCase REST token. Overrides: startOrganizationIssueAutofix / getOrganizationIssueAutofixState, submitProjectUserFeedback->listProjectUserFeedback(structural); unified all preprod ops to PreprodArtifact casing and fixed the latest-base singleton to getOrganizationPreprodArtifactSnapshotLatestBase.
1 parent fc897ca commit df07690

21 files changed

Lines changed: 68 additions & 34 deletions

src/sentry/feedback/endpoints/project_user_reports.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@ class ProjectUserReportsEndpoint(ProjectEndpoint):
4444
authentication_classes = ProjectEndpoint.authentication_classes + (DSNAuthentication,)
4545

4646
@extend_schema(
47-
operation_id="List a Project's User Feedback",
47+
operation_id="listProjectUserFeedback",
48+
summary="List a Project's User Feedback",
4849
parameters=[CursorQueryParam],
4950
)
5051
def get(self, request: Request, project) -> Response:

src/sentry/monitors/endpoints/organization_monitor_checkin_index.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ class OrganizationMonitorCheckInIndexEndpoint(MonitorEndpoint, MonitorCheckInMix
2525
owner = ApiOwner.CRONS
2626

2727
@extend_schema(
28-
operation_id="Retrieve Check-Ins for a Monitor",
28+
operation_id="listOrganizationMonitorCheckins",
29+
summary="Retrieve Check-Ins for a Monitor",
2930
parameters=[
3031
GlobalParams.ORG_ID_OR_SLUG,
3132
MonitorParams.MONITOR_ID_OR_SLUG,

src/sentry/monitors/endpoints/organization_monitor_details.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ class OrganizationMonitorDetailsEndpoint(MonitorEndpoint, MonitorDetailsMixin):
3535
owner = ApiOwner.CRONS
3636

3737
@extend_schema(
38-
operation_id="Retrieve a Monitor",
38+
operation_id="getOrganizationMonitor",
39+
summary="Retrieve a Monitor",
3940
parameters=[
4041
GlobalParams.ORG_ID_OR_SLUG,
4142
MonitorParams.MONITOR_ID_OR_SLUG,
@@ -57,7 +58,8 @@ def get(
5758
return self.get_monitor(request, project, monitor)
5859

5960
@extend_schema(
60-
operation_id="Update a Monitor",
61+
operation_id="updateOrganizationMonitor",
62+
summary="Update a Monitor",
6163
parameters=[
6264
GlobalParams.ORG_ID_OR_SLUG,
6365
MonitorParams.MONITOR_ID_OR_SLUG,
@@ -80,7 +82,8 @@ def put(
8082
return self.update_monitor(request, project, monitor)
8183

8284
@extend_schema(
83-
operation_id="Delete a Monitor or Monitor Environments",
85+
operation_id="deleteOrganizationMonitor",
86+
summary="Delete a Monitor or Monitor Environments",
8487
parameters=[
8588
GlobalParams.ORG_ID_OR_SLUG,
8689
MonitorParams.MONITOR_ID_OR_SLUG,

src/sentry/monitors/endpoints/organization_monitor_index.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,8 @@ class OrganizationMonitorIndexEndpoint(OrganizationAlertRuleBaseEndpoint):
8989
permission_classes = (OrganizationAlertRulePermission,)
9090

9191
@extend_schema(
92-
operation_id="Retrieve Monitors for an Organization",
92+
operation_id="listOrganizationMonitors",
93+
summary="Retrieve Monitors for an Organization",
9394
parameters=[
9495
GlobalParams.ORG_ID_OR_SLUG,
9596
OrganizationParams.PROJECT,
@@ -270,7 +271,8 @@ def get(
270271
)
271272

272273
@extend_schema(
273-
operation_id="Create a Monitor",
274+
operation_id="createOrganizationMonitor",
275+
summary="Create a Monitor",
274276
parameters=[GlobalParams.ORG_ID_OR_SLUG],
275277
request=MonitorValidator,
276278
responses={

src/sentry/monitors/endpoints/project_monitor_checkin_index.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ class ProjectMonitorCheckInIndexEndpoint(ProjectMonitorEndpoint, MonitorCheckInM
2525
owner = ApiOwner.CRONS
2626

2727
@extend_schema(
28-
operation_id="Retrieve Check-Ins for a Monitor by Project",
28+
operation_id="listProjectMonitorCheckins",
29+
summary="Retrieve Check-Ins for a Monitor by Project",
2930
parameters=[
3031
GlobalParams.ORG_ID_OR_SLUG,
3132
GlobalParams.PROJECT_ID_OR_SLUG,

src/sentry/monitors/endpoints/project_monitor_details.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ class ProjectMonitorDetailsEndpoint(ProjectMonitorEndpoint, MonitorDetailsMixin)
3535
owner = ApiOwner.CRONS
3636

3737
@extend_schema(
38-
operation_id="Retrieve a Monitor for a Project",
38+
operation_id="getProjectMonitor",
39+
summary="Retrieve a Monitor for a Project",
3940
parameters=[
4041
GlobalParams.ORG_ID_OR_SLUG,
4142
GlobalParams.PROJECT_ID_OR_SLUG,
@@ -55,7 +56,8 @@ def get(self, request: Request, project, monitor) -> Response[MonitorSerializerR
5556
return self.get_monitor(request, project, monitor)
5657

5758
@extend_schema(
58-
operation_id="Update a Monitor for a Project",
59+
operation_id="updateProjectMonitor",
60+
summary="Update a Monitor for a Project",
5961
parameters=[
6062
GlobalParams.ORG_ID_OR_SLUG,
6163
GlobalParams.PROJECT_ID_OR_SLUG,
@@ -79,7 +81,8 @@ def put(
7981
return self.update_monitor(request, project, monitor)
8082

8183
@extend_schema(
82-
operation_id="Delete a Monitor or Monitor Environments for a Project",
84+
operation_id="deleteProjectMonitor",
85+
summary="Delete a Monitor or Monitor Environments for a Project",
8386
parameters=[
8487
GlobalParams.ORG_ID_OR_SLUG,
8588
GlobalParams.PROJECT_ID_OR_SLUG,

src/sentry/notifications/api/endpoints/notification_actions_details.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,8 @@ def convert_args(self, request: Request, action_id: str, *args, **kwargs):
9797
return (parsed_args, parsed_kwargs)
9898

9999
@extend_schema(
100-
operation_id="Retrieve a Spike Protection Notification Action",
100+
operation_id="getOrganizationNotificationsAction",
101+
summary="Retrieve a Spike Protection Notification Action",
101102
parameters=[
102103
GlobalParams.ORG_ID_OR_SLUG,
103104
NotificationParams.ACTION_ID,
@@ -122,7 +123,8 @@ def get(
122123
return Response(body)
123124

124125
@extend_schema(
125-
operation_id="Update a Spike Protection Notification Action",
126+
operation_id="updateOrganizationNotificationsAction",
127+
summary="Update a Spike Protection Notification Action",
126128
parameters=[
127129
GlobalParams.ORG_ID_OR_SLUG,
128130
NotificationParams.ACTION_ID,
@@ -171,7 +173,8 @@ def put(
171173
return Response(put_body, status=status.HTTP_202_ACCEPTED)
172174

173175
@extend_schema(
174-
operation_id="Delete a Spike Protection Notification Action",
176+
operation_id="deleteOrganizationNotificationsAction",
177+
summary="Delete a Spike Protection Notification Action",
175178
parameters=[
176179
GlobalParams.ORG_ID_OR_SLUG,
177180
NotificationParams.ACTION_ID,

src/sentry/notifications/api/endpoints/notification_actions_index.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ class NotificationActionsIndexEndpoint(OrganizationEndpoint):
6060
permission_classes = (NotificationActionsPermission,)
6161

6262
@extend_schema(
63-
operation_id="List Spike Protection Notifications",
63+
operation_id="listOrganizationNotificationsActions",
64+
summary="List Spike Protection Notifications",
6465
parameters=[
6566
GlobalParams.ORG_ID_OR_SLUG,
6667
OrganizationParams.PROJECT,
@@ -121,7 +122,8 @@ def get(
121122
)
122123

123124
@extend_schema(
124-
operation_id="Create a Spike Protection Notification Action",
125+
operation_id="createOrganizationNotificationsAction",
126+
summary="Create a Spike Protection Notification Action",
125127
parameters=[
126128
GlobalParams.ORG_ID_OR_SLUG,
127129
],

src/sentry/preprod/api/endpoints/public/organization_preprod_artifact_install_details.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ class OrganizationPreprodArtifactPublicInstallDetailsEndpoint(OrganizationEndpoi
3939
)
4040

4141
@extend_schema(
42-
operation_id="Retrieve install info for a given artifact",
42+
operation_id="getOrganizationPreprodArtifactInstallDetails",
43+
summary="Retrieve install info for a given artifact",
4344
parameters=[
4445
GlobalParams.ORG_ID_OR_SLUG,
4546
OpenApiParameter(

src/sentry/preprod/api/endpoints/public/organization_preprod_size_analysis.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,8 @@ class OrganizationPreprodPublicSizeAnalysisEndpoint(OrganizationEndpoint):
7070
}
7171

7272
@extend_schema(
73-
operation_id="Retrieve Size Analysis results for a given artifact",
73+
operation_id="getOrganizationPreprodArtifactSizeAnalysis",
74+
summary="Retrieve Size Analysis results for a given artifact",
7475
parameters=[
7576
GlobalParams.ORG_ID_OR_SLUG,
7677
OpenApiParameter(

0 commit comments

Comments
 (0)