gitlab-org--gitlab-foss/doc/user/project/integrations/slack_slash_commands.md

1.9 KiB

stage group info
Create Ecosystem To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments

Slack slash commands (CORE ONLY)

Introduced in GitLab 8.15.

Slack slash commands allow you to control GitLab and view content right inside Slack, without having to leave it. This requires configurations in both Slack and GitLab.

GitLab can also send events (e.g., issue created) to Slack as notifications. This is the separately configured Slack Notifications Service.

NOTE: For GitLab.com, use the Slack app instead.

Configuration

  1. Slack slash commands are scoped to a project. Navigate to the Integrations page in your project's settings, i.e. Project > Settings > Integrations.
  2. Select the Slack slash commands integration to configure it. This page contains required information to complete the configuration in Slack. Leave this browser tab open.
  3. Open a new browser tab and sign in to your Slack team. Start a new Slash Commands integration.
  4. Enter a trigger term. We suggest you use the project name. Click Add Slash Command Integration.
  5. Complete the rest of the fields in the Slack configuration page using information from the GitLab browser tab. In particular, the URL needs to be copied and pasted. Click Save Integration to complete the configuration in Slack.
  6. While still on the Slack configuration page, copy the token. Go back to the GitLab browser tab and paste in the token.
  7. Ensure that the Active toggle is enabled and click Save changes to complete the configuration in GitLab.

Slack setup instructions

Usage

You can now use the Slack slash commands.