You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 5, 2024. It is now read-only.
In v2 we used to be able to pass in the encoding option to get requests to have request return the data back as a Buffer instead of a string. That option is not supported in v3. Instead the docs say to set the json request option to false:
If you need to call an API that returns plain text, XML, animated GIFs etc. then set the json flag to false in your request options.
However, this option isn't even implemented, and if it were implemented it still wouldn't work.
to the get method in src/httpTransport/client.ts with the option encoding set to null causes body to be returned as a Buffer instead of a string - allowing support for binary data. However, it would be great to add support in a more generic fashion for additional request options.
Thanks.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
In v2 we used to be able to pass in the
encoding
option toget
requests to haverequest
return the data back as a Buffer instead of a string. That option is not supported in v3. Instead the docs say to set thejson
request option to false:However, this option isn't even implemented, and if it were implemented it still wouldn't work.
Adding:
to the
get
method insrc/httpTransport/client.ts
with the optionencoding
set tonull
causes body to be returned as a Buffer instead of a string - allowing support for binary data. However, it would be great to add support in a more generic fashion for additional request options.Thanks.
The text was updated successfully, but these errors were encountered: