Did you ever solve this in a better way?
Jul 9, 2020
2
Level 5
Laravel Http Client cURL 61 unrecognised encoding
Hi guys,
Im calling an api from AppStoreConnect from Apple which is https://api.appstoreconnect.apple.com/v1/salesReports and in their documentation it is stated that the 200 response will return Content-Type: gzip
When I call the API using Laravel Http Client with headers
[
'Accept' => 'application/a-gzip',
'Accept-Encoding' => 'gzip, deflate, br'
]
I am getting cURL 61: unrecognised content encoding type.
The solution I am using is to put options 'decode_content' => false using withOptions and then gzdecode the response.
Is there anyway to let the Laravel Http Client to decode the response automatically without gzdecode it using PHP?
Please or to participate in this conversation.