8

Slack インテグレーションをセットアップしようとすると、403 エラーが発生し、ページがハングします。何が原因でしょうか?

これらはURLです

得る bitbucket.org/api/2.0/repositories/MyAccount/repo-name/hooks/?pagelen=100

役職 bitbucket.org/api/2.0/repositories/MyAccount/repo-name/hooks/

他の誰かが bitbucket をよく知っている場合は、リポジトリの削除を防止するオプションもあり、有効にしようとすると !Forbidden メッセージも表示されます。これらは、私のアカウントが無料利用枠にあることに関連していますか? エラーフィードバックはほとんどありません。

4

2 に答える 2

17

edit

From Atlassian's Bitbucket Cloud for Slack how-to:

(Requires repo admin permissions)

  1. Log into Bitbucket
  2. Open a specific repository to add notifications to, in the account that is connected to Slack.
  3. Click Settings then select Chat notifications > Settings.
  4. Choose one of the following:

    • Click Add subscription, if you've already connected this repository to Slack.
    • Click the connect button, if this the first time your
      connecting a repository to your Slack workspace.
    • Click Add subscription and then select Add new workspace, if you’re adding a new subscription, to a new workspace.
  5. Choose the Slack workspace and channel to connect to your repository.

/edit


Not sure how you're trying to do it, but here is how I got mine to work:

  1. Make sure you have the Bitbucket app installed on Slack. It should show up on your yourteam.slack.com/apps/manage page. In case it doesn't, search Bitbucket on the app directory

  2. Once in the Bitbucket app page on Slack, go to its configuration page (or create a new configuration). Decide to which channel or user should Bitbucket notifications be posted.

  3. On the same page, find the Webhook URL. It looks something like https://hooks.slack.com/services/LONGST/RINGOF/RANDOMChAraCTeRS

  4. On your Bitbucket repository page, click Settings/Webhooks.

  5. Use the Slack URL to create a new Webhook. Assign a unique name to it. I believe Slack only supports Repository Push type of trigger.

I hope it works for you.

于 2016-01-08T16:13:31.790 に答える
1

ここで述べたように、Webhook の代わりにチャット通知を使用できます。

  1. Bitbucket にログインする

  2. Slack に接続されているアカウントで、通知を追加する特定のリポジトリを開きます。

  3. [設定]をクリックし、[チャット通知] > [設定]を選択します。次のいずれかを選択します。

    1. このリポジトリを既に Slack に接続している場合は、 [サブスクリプションの追加] をクリックします。
    2. 初めてリポジトリを Slack ワークスペースに接続する場合は、接続ボタンをクリックします。
    3. [サブスクリプションの追加] をクリックし、新しいサブスクリプションを新しいワークスペースに追加する場合は、 [新しいワークスペースの追加]を選択します。
  4. リポジトリに接続する Slack ワークスペースとチャネルを選択します。


[チャット通知] > [設定]/bitbucket connect <repository URL>を使用するか、以前に Bitbucket に接続した Slack ワークスペースに入力して、追加のリポジトリをサブスクライブできます。

于 2019-04-08T21:18:09.640 に答える