Change existing Slack slash commands endpoint route to match new events endpoint route
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
This issue came out of this discussion #358676 (comment 934072419).
About
The API endpoint that processes Slack events #358676 (closed) is defined in API::Integrations::Slack::Events
and the route is api/v4/integrations/slack/events
.
The older API endpoint that processes Slack slash commands is related, but currently is defined in API::Integrations
and the route is api/v4/slack/trigger
.
Without any breaking changes, we would like to rename the class and route of the slash commands endpoint to match the events endpoint.
The benefits of this refactor is:
- Improved code consistency.
- Developers will understand the relationship more easily.
- Aids code discoverability.
Proposal
-
Move the definition of the API endpoint to a new API::Integrations::Slack::SlashCommands
class. -
Rename the route to api/v4/integration/slack/slash_commands
(note:slash_commands
and nottrigger
). -
Redirect the old route to the new route. -
Once deployed to .com: Update the GitLab (dev) Slack app and production Slack app to use the new route (don't publish the production Slack app)
Edited by 🤖 GitLab Bot 🤖