-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not able to set Content-Type with UTF-8 in header #144
Comments
I was actually able to set it like the following:
I previously tried using the creation options |
Hi @Nordes , you can set headers using the options 'headers': client.post({
headers: {
'content-type': 'foobarbaz'
},
path: '/'
}, function() { ... }); That said, for content-type specifically, we seem to be deleting content-type headers for GET/HEAD/DELETE verbs. While generally this seems reasonable, in reading the RFC it doesn't actually suggest that content-type is required (or disallowed) based on the verbs. This seems like a legitimate bug. |
Hi, maybe I am doing it wrong, but I am not able to set the CharSet in the headers.
(Needed to send some japanese body)
Usually in postman: Content-Type: application/json; charset=UTF-8
I`ve tried to set the headers :
But it fails. It still send the wrong text.
The text was updated successfully, but these errors were encountered: