The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to send PAYLOAD_FILE in slack pipe

Aliaksandr Prytychanka
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 17, 2024

pipelines: default:

- step: name: Notify Slack

script: - apt-get update && apt-get install gettext-base

- envsubst < "payload.json.template" > "payload.json"

- pipe: atlassian/slack-notify:2.3.0

variables:

WEBHOOK_URL: $WEBHOOK_URL

PAYLOAD_FILE: payload.json

CHANEEL: '#dev'

 

 

With these variables set and the exact correct payload.json.template of the correct format, the pipe crashes with an error


 

Digest: sha256:b198a727fadf804c850a76adb13e5bb7cc58c56c526dc6425d254cbc860d7ea0
83
Status: Downloaded newer image for bitbucketpipelines/slack-notify:2.3.0
84
INFO: Starting with payload provided in PAYLOAD_FILE...
85
INFO: Sending notification to Slack
86
✖ Notification failed. Pipe has finished with an error: Invalid URL '': No scheme supplied. Perhaps you meant https://?

Could you please advise how to make this work? Normal messages are sent

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Igor Stoyanov
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 19, 2024

Hi @Aliaksandr Prytychanka . The error you provided points you with Invalid URL '' (empty string). 

Check/update the repository variable $WEBHOOK_URL you used in the pipe.

Regards, Igor

DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events