Setting up Bitbucket Cloud Webhook for Fisheye

Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

Summary

Since Fisheye's REST API Token requires Request Headers which is not supported by Bitbucket's Webhook, you would require generating a User Token and add it as part of the Webhook URL.

Solution

Steps

  1. Get Fisheye's User token by running the following command:

    1 2 curl -X POST --header 'content-type: application/x-www-form-urlencoded' --data 'userName=<Your_Username>&password=<Your_password>' --url <Your_URL>:<PORT></optional CONTEXT>/rest-service-fecru/auth/login eg. curl -X POST --header 'content-type: application/x-www-form-urlencoded' --data 'userName=UserA&password=MyPassword' --url http://hostname:8060/fecru/rest-service-fecru/auth/login

    ℹ️ It should return a similar output -> {"token":"<username>:2:73c6729f7f5941de6841eca87860dfa0"}

    Documentation: Fisheye Crucible REST API

  2. With the token received from the API, you can add the following URL to your Bitbucket's Webhook's URL then select your preferred triggers to proceed:

    1 2 <Your_URL>:<PORT></optional CONTEXT>/rest-service-fecru/admin/repositories-v1/<Your_Repo_Name>/scan?FEAUTH=<Your_User_Token> eg. http://hostname:8060/fecru/rest-service-fecru/admin/repositories-v1/ronc/scan?FEAUTH=admin:2:73c6729f7f5941de6841eca87860dfa0

    ⚠️ Please ensure that your URL is publicly accessible before adding to your Repository's Webhook

    Documentation: Authenticating REST Request

Updated on April 17, 2025

Still need help?

The Atlassian Community is here for you.