# Getting issues from specific branch through api

**URL:** <https://community.sonarsource.com/t/getting-issues-from-specific-branch-through-api/1909>\
**Category:** SonarQube Server / Community Build\
**Tags:** branches, web\_api, sonarqube\
**Created:** [August 21, 2018, 5:04am UTC](https://community.sonarsource.com/t/getting-issues-from-specific-branch-through-api/1909 "2018-08-21T05:04:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![vicky](https://avatars.discourse-cdn.com/v4/letter/v/b19c9b/32.png) [@vicky](https://community.sonarsource.com/u/vicky)\
**Post date:** [August 21, 2018, 5:04am UTC](https://community.sonarsource.com/t/getting-issues-from-specific-branch-through-api/1909/1 "2018-08-21T05:04:47Z")

</div>

Hi,

I am trying to

> get all the issues with respect to specific branch only

(not issues from master and other branchs) and when i am calling the api ( [http://localhost:9000/api/issues/search?branch=dev&id=typescript%3Atypescript&resolved=false](http://localhost:9000/api/issues/search?branch=dev&id=typescript%3Atypescript&resolved=false)) it is giving the issues from master branch as well and that’s weird as i have already specified search?branch=dev.  
Can anyone help please?  
Thanks in advance!

---

<div class="post-metadata">

**Author:** ![vicky](https://avatars.discourse-cdn.com/v4/letter/v/b19c9b/32.png) [@vicky](https://community.sonarsource.com/u/vicky)\
**Post date:** [August 21, 2018, 5:43am UTC](https://community.sonarsource.com/t/getting-issues-from-specific-branch-through-api/1909/2 "2018-08-21T05:43:29Z")

</div>

Hi,

It seems like i was passing the parameters in wrong way but while trying this way i got the issues and it might help someone so here is the link [http://localhost:9000/api/issues/search?componentKeys=typescript:typescript&resolved=false&branch=dev](http://localhost:9000/api/issues/search?componentKeys=typescript:typescript&resolved=false&branch=dev).

---

<div class="post-metadata">

**Author:** ![rishad-mj](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rishad-mj/32/18808_2.png) [@rishad-mj](https://community.sonarsource.com/u/rishad-mj)\
**Post date:** [November 12, 2021, 2:50pm UTC](https://community.sonarsource.com/t/getting-issues-from-specific-branch-through-api/1909/3 "2021-11-12T14:50:25Z")

</div>

Hi, even I’m facing the same issue. Trying to fetch issues with respect to Specific branch . But it always giving me the issue count from the Master branch.  
Below is the API

[https://sonarserver.com/api/issues/search?resolved=false&types=BUG&branch=SonarQube\_Analysis\_5.10.0.2](https://sonarserver.com/api/issues/search?resolved=false&types=BUG&branch=SonarQube_Analysis_5.10.0.2)

Sonarqube DeveloperEdition version 8.9.1
