Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Webhook URL Error for Send Microsoft Teams Message action webhookb2

JG Meillaud _ January 21, 2021

Hello,

I cannot enable the Send MS Teams Message action because Automation tells me the webhook URL is not OK.

The webhook URL looks like this https://COMPANY.webhook.office.com/webhookb2/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXXXXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/IncomingWebhook/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX

Automation gives me a warning sign /!\ and "Please enter a valid webhook URL like https://outlook.office.com/webhook/XXXXYYYY..."

Thanks a lot!

9 answers

1 accepted

3 votes
Answer accepted
Gareth Cantrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 8, 2021

After upgrading to Automation for Jira 7.2.6, you need to following the documentation at https://confluence.atlassian.com/automation/setting-configuration-properties-1026539532.html to set the ms.teams.notification.action.url.prefix property to the correct prefix.

If you don't set the prefix, it will default to https://outlook.office.com/webhook/

If you need both the old and new prefix, set the prefix to https:// so that it matches any secure URL.

Stephan Stahl February 9, 2021

Worked perfectly for me after updating Automation for Jira to 7.2.6! Thanks for pointing out the instructions Gareth, much appreciated!

Like Gareth Cantrell likes this
Leonie C_ Breitmoser February 9, 2021

Worked for us as well. Thanks for pointing us in the right direction Gareth.

Like Gareth Cantrell likes this
0 votes
Aditya Verma April 29, 2021

I am facing the same issue on Jira Data Center + A4J v7.2.8.  Can you please suggest a solution for it ?

@Gareth Cantrell  @Sherry Goyal 

Gareth Cantrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 29, 2021

@Aditya Verma the instructions I referred to above are for Jira Data Center/Server. If you're running Windows servers, use the script posted by @Erik Ekengren above.

Aditya Verma May 3, 2021

Thanks @Gareth Cantrell , I was able to follow it.

Like Gareth Cantrell likes this
0 votes
Erik Ekengren March 4, 2021

Hi all!

I tried the work-around in this article Setting configuration properties | Automation for Jira Data Center and Server 7.2 | Atlassian Documentation but had no luck. It turned out that since I run Jira on WINDOWS-machine then I was not able to use the CURL-command. After some talks with the Atlassian support they helped me with this Power-shell query and then I got it working:

$user = 'YOUR_USER_ADMIN'
$pass = 'PASSWORD'
$pair = "$($user):$($pass)"
$encodedCreds = [System.Convert]::ToBase64String([System.Text.Encoding]::ASCII.GetBytes($pair))
$basicAuthValue = "Basic $encodedCreds"
$Headers = @{
Authorization = $basicAuthValue
}
$Uri = 'https://<jira-base-url>/rest/cb-automation/1/configuration/property/bulk'
$Form = @{
"ms.teams.notification.action.url.prefix"="https://"
}
Invoke-WebRequest -Uri $Uri -Method Put -Body ($Form|ConvertTo-Json) -ContentType "application/json" -Headers $Headers

Change User and Password in the script and also to your Base-url and this will work. This will allow all webhooks that starts with https://.

Fox Chen March 22, 2021

Hi Erik,

May I ask how to run the script? Thank you.

BR,
Fox

Erik Ekengren March 23, 2021

Hi Fox!

Log in to your Windows Server and open Powershell. Then copy this (replace user and password and also <jira-base-url> to the base URL you have) to Powershell and run it:

$user = 'YOUR_USER_ADMIN'
$pass = 'PASSWORD'
$pair = "$($user):$($pass)"
$encodedCreds = [System.Convert]::ToBase64String([System.Text.Encoding]::ASCII.GetBytes($pair))
$basicAuthValue = "Basic $encodedCreds"
$Headers = @{
Authorization = $basicAuthValue
}
$Uri = 'https://<jira-base-url>/rest/cb-automation/1/configuration/property/bulk'
$Form = @{
"ms.teams.notification.action.url.prefix"="https://"
}
Invoke-WebRequest -Uri $Uri -Method Put -Body ($Form|ConvertTo-Json) -ContentType "application/json" -Headers $Headers

BR/

Erik

Fox Chen March 23, 2021

it works, thank you so much.

Like Erik Ekengren likes this
0 votes
Leonie C_ Breitmoser February 8, 2021

Hi there,

we run into the same issue. Even with the bugfix update it won't work with the web-hook in our Jira. (Server 8.13.1 & Automation 7.2.6).

I tried to find out if I need to change something in the setup, but didn't succeed. I still get the "lease enter a valid webhook URL like https://outlook.office.com/webhook/XXXXYYYY..." Error Message. 

Did anyone find a solution for this?

Thanks,

Leonie

robert Mugabuhamye
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 8, 2021

Hello @Leonie C_ Breitmoser

II'm still experiencing the issue on the 7.2.6 version too 😔.

No solutions so far 

Gareth Cantrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 9, 2021

@robert Mugabuhamye 7.2.6 does indeed contain a solution for this issue, however it requires you make some configuration changes post installation.

It is not immediately obvious, until you read the release notes in conjunction with the documentation on setting configuration properties (see my answer above).

Like robert Mugabuhamye likes this
robert Mugabuhamye
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 29, 2021

@Gareth Cantrell forgot to thank you. It worked for us 🙏🏿

Like Gareth Cantrell likes this
0 votes
robert Mugabuhamye
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 1, 2021

hello @Sherry Goyal  

We are seeing this issue on Jira datacenter + automation 7.1.17

Do you know by any chance in which version of Automation this has been corrected?

thanks

Sherry Goyal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 1, 2021

Hello @robert Mugabuhamye

We fixed it in cloud. Sorry I am not aware of the server.

Gareth Cantrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 4, 2021

@robert Mugabuhamye I see there was a new version for server that was released on 28/Jan that appears to address the MS Teams issues (version 7.2.6)

robert Mugabuhamye
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 4, 2021

Thank you @Gareth Cantrell , I'm going to try that version

0 votes
Sherry Goyal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 28, 2021

Hello All,

Since Microsoft url has changed over time, we have removed the validation from Automation side in cloud. The new URL should be working now. Please let me know in case of issues. Apologies for the inconvenience.

Cheers
Sherry

0 votes
JG Meillaud _ January 25, 2021

Hi both,

Thanks for replying.

So this is a known bug:
[AUT-2103] Microsoft Teams webhooks are limited to specific URL

What's really frustrating is that it looks like this "URL verification" thing is a feature...
If so, please Atlassian and partners, keep it simple, please 🙏.

Cheers,
JG

0 votes
Gareth Cantrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 22, 2021

Microsoft is apparently changing the format of all newly created Webhook URLs after 11/Jan, and the older "outlook.office.com/webhook" will be deprecated in 3 months

If you have access to the Microsoft365 Message Center, you can view the announcement here: https://admin.microsoft.com/AdminPortal/home?ref=MessageCenter&id=MC234048

I'd suggest raising a support request with Atlassian to address this.

0 votes
Резниченко Дмитрий Юрьевич
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!
January 22, 2021

We have same problem!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events