debian-mirror-gitlab/lib/api/integrations/slack/events/url_verification.rb
2022-07-29 14:03:07 +02:00

22 lines
629 B
Ruby

# frozen_string_literal: true
module API
class Integrations
module Slack
class Events
class UrlVerification
# When the GitLab Slack app is first configured to receive Slack events,
# Slack will issue a special request to the endpoint and expect it to respond
# with the `challenge` param.
#
# This must be done in-request, rather than on a queue.
#
# See https://api.slack.com/apis/connections/events-api.
def self.call(params)
{ challenge: params[:challenge] }
end
end
end
end
end
end