MS Teams authorization failing with: "Failed to generate authorization link"
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Problem
When trying to authorize the connection between Jira and MS Teams it fails with:
"Failed to generate authorization link. Please contact your Jira Server administrator and confirm Application link for Microsoft Teams app has been properly configured."

Diagnosis
Diagnostic Steps
Navigate to Administration > System > Logging and profiling
Scroll up and go to the "Mark Logs" section above
At the "Optional Message" field insert MSTeams starts here
Under HTTP Access Logging, click inEnable the HTTP access log, also click onEnable the HTTP dump log
Under "Default Loggers" section, click on Configure logging level for another package
At the "Package name" field, enable TRACEfor the following packages:
1
2
org.apache.http
com.microsoft.teams
On the trace you will see:
1
2
3
4
5
6
7
8
9
10
2023-08-04 09:39:19,297-0400 RxCachedThreadScheduler-1 DEBUG AGUDIPEL 727x2292114x6 1hbs75q 10.137.206.28,10.190.64.13 /rest/plugins/1.0/available/featured [c.m.teams.utils.ExceptionHelpers] getAndAuthorizeTemporaryTokenWithUrl error com.google.api.client.http.HttpResponseException: 401
POST https://jira.cablevision.com/plugins/servlet/oauth/request-token
oauth_problem=consumer_key_unknown
ROOT CAUSE: HttpResponseException: 401
POST https://jira.cablevision.com/plugins/servlet/oauth/request-token
oauth_problem=consumer_key_unknown
EXCEPTION STACK TRACE: com.google.api.client.http.HttpResponseException: 401
POST https://jira.cablevision.com/plugins/servlet/oauth/request-token
oauth_problem=consumer_key_unknown
at com.google.api.client.http.HttpResponseException$Builder.build(HttpResponseException.java:293)
Cause
This is caused by incorrect Application Link Type. MS Team uses OAuth 1.0, so when creating the Application Link you need to select Application Type "Atlassian Products", that uses OAuth 1.0.
Solution
Resolution
Recreate the Application Link, selecting Application Type "Atlassian Products":

Was this helpful?