Hello Community,
I was using REST API 2 to integrated JIRA SD Cloud data with Power BI and it was working well. Due to the new update of API 3, the integration not working and keep giving error 410 access blocked! Below the Queries (5 components) that I used in Power BI:
URL:
"https://NAME.atlassian.net/" meta [IsParameterQuery=true, Type="Any", IsParameterQueryRequired=true]
_____________________________________________________
GenerateByPage:
(getNextPage as function, optional tableType as type) as table =>
let
listOfPages = List.Generate(
() => getNextPage(null),
(lastPage) => lastPage <> null,
(lastPage) => getNextPage(lastPage)
),
tableOfPages = Table.FromList(listOfPages, Splitter.SplitByNothing(), {"Column1"}),
firstRow = tableOfPages{0}?,
keys = if tableType = null then Table.ColumnNames(firstRow[Column1])
else Record.FieldNames(Type.RecordFields(Type.TableRow(tableType))),
appliedType = if tableType = null then Value.Type(firstRow[Column1]) else tableType
in
if tableType = null and firstRow = null then
Table.FromRows({})
else
Value.ReplaceType(Table.ExpandTableColumn(tableOfPages, "Column1", keys), appliedType)
_____________________________________________________
FetchPages:
I can see you're getting an error when trying to use the REST API to search for Jira issues. This is most likely being caused by that old search endpoint has been deprecated, see https://developer.atlassian.com/changelog/#CHANGE-2046
Fortunately, there is an updated endpoint you can use that should provide the same kind of information, see https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-search/#api-rest-api-3-search-jql-get
I think you will need to change the syntax you have of:
/rest/api/3/search?jql=project=ProjectName
into:
/rest/api/3/search/jql?jql=project=ProjectName
That should then return results. If you're getting an error using this endpoint, let me know what error/results are returned.
Jira has a tendency to allow for anonymous calls to endpoints like search, so if your authorization failed, you might just get back 0 issues that an anonymous user would see. But if you're calling the old deprecated endpoint the error is likely to be different and halting for all queries.
Andy
Thanks Andy, it working well now.
Much appreciated :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Andy H ,
the connection work well but it keep loading infinity / non stopping. Even after testing, not showing all fields only showing one field Column1.id. Could you please support this?
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Regional Administrator I am not as familiar with using Power BI to do this. Perhaps it has something to do with switching to the v3 API as well here. Maybe you can tweak the call to still use the v2 endpoint, but the newer one.
Try using
/rest/api/2/search/jql?jql=project=ProjectName
And see if that helps. If not, I'm not sure what else could be different here aside from the old endpoint being deprecated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Andy H , I was hoping you could help me with an issue I’m encountering:
I was using the rest/api/3 endpoint in this format:
let path = "/3/search?maxResults=100&jql=project in (ProjectA, ProjectB, ProjectC) and createdDate >= ""2023/01/01""", res = "100", start = "0",
(...)
As of yesterday, I started receiving this error and can no longer refresh any of the reports:
DataSource.Error: Web.Contents failed to get contents from 'https://........atlassian.net/rest/api/3/search?maxResults=100&jql= (...)' (410): Gone
I updated the query as you suggested:
let path = "/rest/api/3/search/jql?jql=project in (ProjectA, ProjectB, ProjectC) and createdDate >= ""2023/01/01""", res = "100", start = "0", (...)
But now I’m receiving this error:
DataSource.Error: Web.Contents failed to get contents from 'https://.........atlassian.net/rest/api/rest/api/3/search/jql?jql=(...)' (404): Not Found
Details: DataSourceKind=Web
(...)
My credentials are valid, and I’ve also generated a new token, but it didn’t resolve the issue.
Any ideas on what might be causing this?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am having the exact same issue! All my JIRA reports are currently not working. Please someone help. :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Artur Nogaj Based on the error you are getting back, the path being called has extra parameters in it:
DataSource.Error: Web.Contents failed to get contents from 'https://.........atlassian.net/rest/api/rest/api/3/search/jql?jql=(...)' (404): Not Found
You're error message shows the problem:
/rest/api/rest/api/3/search/jql?jql
should instead look like:
/rest/api/3/search/jql?jql
You have an extra '/rest/api/' in the path being called.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi All
Slightly late to all of this as I only check my dashboards every 3 months.
So this was a major head wrecker for me as my connection was a simple GET using the v2 Rest API link and just connecting from Power BI using my login and Token. Going into Advanced Editor was way out of my skillset - but I have some code which works!!!
So start with a New Source - Blank Query in Power Query in Power BI. Select Avanced Editor and delete what comes up. Then paste the code in below - changing the Jira Site, Email Address (used for making the API Token in Jira), and the Token itself. And the Jira Project Short Code you want to look up, or alternate JQL (it must be limiting). It should then get you to the same (or similar) starting point for the old GET v2 API connection. Hope this helps someone!!!!
PS apologies the forum won't let me post the code so I've provided it as an picture attachment and a link to a word doc below (expires 10 Nov 2026)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This works ! but why all the records are duplicated ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.