Skip to content

Unleash Android SDK is not sending mandatory appName for frontend metrics #113

@andreaobitz

Description

@andreaobitz

Describe the bug

When integrating the Unleash Android SDK into an Android (Kotlin) project, the SDK automatically sends HTTP POST requests to the /client/metrics endpoint. These requests include the header:

Content-Type: application/json;charset=utf-8

This header is set internally by the SDK and includes the charset=utf-8 parameter by default. I couldn't find any configuration option in the SDK to modify or remove the charset=utf-8 part from the Content-Type header.

Steps to reproduce the bug

  1. Add the Unleash Android SDK to an Android project
  2. Run the app and observe network traffic via a proxy tool such as Proxyman
  3. Notice POST requests to /client/metrics with header Content-Type: application/json;charset=utf-8
  4. Attempt to find SDK configuration to change this header — none available

Expected behavior

It should be possible to customize or remove the charset=utf-8 parameter from the Content-Type header in the metrics requests, as some backend servers or proxies may reject or mishandle this header

Logs, error output, etc.

Screenshots

Image Image

Additional context

Unleash Android SDK version: io.getunleash:unleash-android version 2.0.1
Android Studio version:
Android Studio Meerkat Feature Drop | 2024.3.2
Build #AI-243.25659.59.2432.13423653, built on April 29, 2025
Runtime version: 21.0.6+-13368085-b895.109 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Toolkit: sun.awt.windows.WToolkit
Windows 11.0
GC: G1 Young Generation, G1 Concurrent GC, G1 Old Generation
Memory: 2048M
Cores: 28
Registry:
ide.experimental.ui=true
io.getunleash:unleash-android
Android device: Motorola moto g34 5G, Android 15
Network proxy tool: Proxyman

Unleash version

2.0.1

Subscription type

None

Hosting type

None

SDK information (language and version)

No response

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions