Countly / countly-sdk-flutter-bridge

Flutter SDK for Countly Product Analytics Platform
https://count.ly
MIT License
29 stars 19 forks source link

Unable to add custom network request headers #282

Open sbatezat opened 3 days ago

sbatezat commented 3 days ago

On Android, I'm able to addCustomNetworkRequestHeaders() (see https://support.countly.com/hc/en-us/articles/360037754031-Android#h_01HAVQDM5W8GFBCZ3B8CFT5BHF)

I do not know if it's available on iOS, but I need it. On iOS, I'm also able to do it through URLSessionConfiguration Example :

// Add custom network request header
let session = URLSessionConfiguration.default
let customHeader = ["KEY": "value"]
session.httpAdditionalHeaders = customHeader
config.urlSessionConfiguration = session

On Flutter, there is no such method (not found on https://support.countly.com/hc/en-us/articles/360037944212-Flutter#h_01H930GAQ8DQ2KJTQCAFZTRHD9)

turtledreams commented 3 days ago

Hi @sbatezat, yes we don't give that option in Flutter yet. We will try to add it to next release if there won't be any blockers. Thank you for bringing it up.