Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

API to retrieve list of all boards

Hello everyone. 

I am building an addon for Jira, and need an API to retrieve list of all boards in a project. I see an api to get details of a board GET /rest/agile/1.0/board/{boardId}

But I don't see any API to get list of all boards in a project.

 

Thanks,

Kranthi

1 answer

If you want to filter boards for a particular project you should use projectKeyOrId query parameters as specified in the link.

Tuncay

It looks like this endpoint does not exist when using cloud platform, and is no longer supported when using the server API (you are required to use a filter ID, although the filter can be an empty filter, the filter must still exist), see

The Jira Software Cloud REST API

The Jira Cloud platform REST API

Do you have a recommended approach given the available endpoints in the documentation? I know I am just speaking with other members of the community and not atlassian but sometimes we come up with some cool tricks :)

Like ArunRaghavendar_A likes this

Use case if it helps :

The best advice online for getting a list of all valid sprint values is here,

https://stackoverflow.com/questions/37821683/how-to-get-all-sprints-in-project-using-jira-rest-api

You cannot use the createmeta or editmeta endpoint to look up which sprint values are valid without unlocking the type, which requires administrative permissions. There is no allowedValues list for sprints. When creating an issue, to assign to a sprint, you need the sprint ID and board ID. To retrieve the sprint IDs, you have to know the board ID, and thus, there is a need to look up board IDs.

In other words, without the ability to look up all board IDs available to an account, you are effectively working blind and encouraging developers to hard code values which are not coming from the server and therefore may become invalid or out of date as projects change, for example, if a team recreates a Jira board or the company restructures.

Just an update, it turns out even though it is not available in the most recent documentation I linked previously, you can indeed hit /rest/agile/1.0/board without using a filter and use getAllBoards() using the server API under API 1.0 as of 2021-11-30. Since this did not make it into the most recent documentation, this is a get endpoint and arguments are startAt and maxResults for pagination, and type (scrum, kanban), name, and projectKeyOrId.

Since this is effectively an "Easter egg", should Atlassian remove this functionality, I was able to verify

  • setting up a generic filter through Jira's frontend pulling up all available boards
  • using getBoardByFilterId with this generic filter

Is a futureproof substitute for getAllBoards

Since this information was difficult to locate in Atlassian's documentation and may be why people discovered this post through a search engine, I am also providing data contracts for Sprint and Board. Only one of boardId or originBoardId are returned by the API, and they are synonymous.

public class Sprint
{
public int id;
public String name;
public State state;
public int boardId, originBoardId;
public String self;
public Date startDate;
public Date endDate;
public Date completeDate;
public String goal;

public static enum State { FUTURE, ACTIVE, CLOSED }
}

 

public class Board
{
public int id;
public String self;
public String name;
public BoardType type;
public Location location;

public static enum BoardType { SCRUM, KANBAN }
}
public class Location
{
public int projectId;
public String displayName;
public String projectName;
public String projectKey;
public String projectTypeKey;
public String avatarURI;
public String name;
}

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS
Community showcase
Published in Jira Software

👋 Looking for 15-20 volunteers to test Atlassian training content

Hi everyone! Are you interested in beta testing Atlassian University’s newest (unreleased!) training course? We’re looking for 15-20 volunteers to test our newest training course, Basic reporting...

867 views 25 28
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you