# Web API: Using api/measures/ how do i GET code coverage for multiple componentKeys (projects)?

**URL:** <https://community.sonarsource.com/t/web-api-using-api-measures-how-do-i-get-code-coverage-for-multiple-componentkeys-projects/105365>\
**Category:** SonarQube Cloud\
**Tags:** web\_api, coverage\
**Created:** [December 1, 2023, 3:02pm UTC](https://community.sonarsource.com/t/web-api-using-api-measures-how-do-i-get-code-coverage-for-multiple-componentkeys-projects/105365 "2023-12-01T15:02:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ChrisC1](https://avatars.discourse-cdn.com/v4/letter/c/5e9695/32.png) [@ChrisC1](https://community.sonarsource.com/u/ChrisC1)\
**Post date:** [December 1, 2023, 3:02pm UTC](https://community.sonarsource.com/t/web-api-using-api-measures-how-do-i-get-code-coverage-for-multiple-componentkeys-projects/105365/1 "2023-12-01T15:02:59Z")

</div>

Can i use api/measures/component witht multiple componentKeys so i can return code coverage for more than just 1 repo?

What would be an example format when searching for more than just 1 componentKey?

Or, can i retrieve code coverage for all projects in my org, using another method?

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [December 4, 2023, 4:19pm UTC](https://community.sonarsource.com/t/web-api-using-api-measures-how-do-i-get-code-coverage-for-multiple-componentkeys-projects/105365/2 "2023-12-04T16:19:40Z")

</div>

Hi,

Welcome to the community!

Have you tried it?

&nbsp;  
🙂  
Ann

---

<div class="post-metadata">

**Author:** ![ChrisC1](https://avatars.discourse-cdn.com/v4/letter/c/5e9695/32.png) [@ChrisC1](https://community.sonarsource.com/u/ChrisC1)\
**Post date:** [December 4, 2023, 4:36pm UTC](https://community.sonarsource.com/t/web-api-using-api-measures-how-do-i-get-code-coverage-for-multiple-componentkeys-projects/105365/3 "2023-12-04T16:36:42Z")

</div>

Yes, i can’t find a solution to retrieve multiple componentKeys with their respective code coverage values.

Please can you give me a hint, it would be an early xmas present for me.

Thanks

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [December 4, 2023, 4:42pm UTC](https://community.sonarsource.com/t/web-api-using-api-measures-how-do-i-get-code-coverage-for-multiple-componentkeys-projects/105365/4 "2023-12-04T16:42:08Z")

</div>

Hi,

The web services were built to service the UI. So if you don’t see something happen in the UI, it’s likely not doable via the API. That said, multiple projects are displayed together - _with measures_ - on the projects page.

The best way to master the API is to perform the desired action via the UI and eavesdrop to see which calls the UI made to accomplish the action.

You may also find [this guide](https://community.sonarsource.com/t/how-to-reverse-engineer-the-sonar-web-api/66810) helpful.

&nbsp;  
HTH,  
Ann
