# Build Artifact MetaData for Android App Bundle is not working as expected

**URL:** <https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776>\
**Category:** Development\
**Tags:** api, android\
**Created:** [February 14, 2024, 11:58am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776 "2024-02-14T11:58:47Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jigneshCupid](https://avatars.discourse-cdn.com/v4/letter/j/a88e4f/32.png) [@jigneshCupid](https://discuss.bitrise.io/u/jigneshCupid)\
**Post date:** [February 14, 2024, 11:58am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776/1 "2024-02-14T11:58:47Z")

</div>

We are fetching info and downloading builds using Bitrise API for our internal tooling.

APIs Used: [Managing build artifacts - Bitrise Docs](https://devcenter.bitrise.io/en/api/managing-build-artifacts.html)

This is working as expected for APK files on Android.

While we are exploring support for AAB (Android App Bundle) we found one small issue on meta data for `artifact_type`. Other MetaData fields looks okay.

**Steps:**

- Build APK and Upload Artifact
- Build AAB and Upload Artifact
- Fetch Artifact Details Using Bitrise API
- Observe for `artifact_type` field in both cases.

**Current behavior**  
Bitrise API Return “artifact\_type”=\>“android-apk” for AAB

**Expected behavior**  
Expected: “artifact\_type”=\>“android-aab” or similar

---

<div class="post-metadata">

**Author:** ![BalazsIlsinszki](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/balazsilsinszki/32/4428_2.png) [@BalazsIlsinszki](https://discuss.bitrise.io/u/BalazsIlsinszki)\
**Post date:** [February 15, 2024, 9:09am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776/2 "2024-02-15T09:09:48Z")

</div>

Hey @jigneshCupid,

Could you please reach out to support and we will take a look at your build.  
[https://support.bitrise.io/hc/en-us/requests/new](https://support.bitrise.io/hc/en-us/requests/new)

Have a nice day!  
Balazs

---

<div class="post-metadata">

**Author:** ![kaushal.bitrise](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/kaushal.bitrise/32/5305_2.png) [@kaushal.bitrise](https://discuss.bitrise.io/u/kaushal.bitrise)\
**Post date:** [February 15, 2024, 9:54am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776/3 "2024-02-15T09:54:27Z")

</div>

Hi @jigneshCupid

If you look at the entire API response, data[0].artifact\_meta.aab field should have a file path when it is an aab instead of an apk. You can use this to fetch info/download AAB builds using the API.

---

<div class="post-metadata">

**Author:** ![jigneshCupid](https://avatars.discourse-cdn.com/v4/letter/j/a88e4f/32.png) [@jigneshCupid](https://discuss.bitrise.io/u/jigneshCupid)\
**Post date:** [February 15, 2024, 11:12am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776/4 "2024-02-15T11:12:06Z")

</div>

Yes @kaushal.bitrise, we are using this way currently. Thanks for this confirmation on the same.

So, does it safe to assume this is the minor bug here?  
Hopefully this can be tracked with respective team and maybe fixed in upcoming versions.

---

<div class="post-metadata">

**Author:** ![kaushal.bitrise](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/kaushal.bitrise/32/5305_2.png) [@kaushal.bitrise](https://discuss.bitrise.io/u/kaushal.bitrise)\
**Post date:** [February 15, 2024, 11:26am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776/5 "2024-02-15T11:26:40Z")

</div>

Good to hear you’re going to continue using it with this field @jigneshCupid

The `artifact_type` filed is intended for users to filter between iOS and Android, and not the file extension specifically, per se. It’s current behaviour is by design. I appreciate your feedback on this.

---

<div class="post-metadata">

**Author:** ![jigneshCupid](https://avatars.discourse-cdn.com/v4/letter/j/a88e4f/32.png) [@jigneshCupid](https://discuss.bitrise.io/u/jigneshCupid)\
**Post date:** [February 15, 2024, 11:52am UTC](https://discuss.bitrise.io/t/build-artifact-metadata-for-android-app-bundle-is-not-working-as-expected/23776/6 "2024-02-15T11:52:28Z")

</div>

Noted, thanks @kaushal.bitrise for sharing this.
