Questions tagged [x-www-form-urlencoded]
139 questions
344
votes
17 answers
How do I POST a x-www-form-urlencoded request using Fetch?
I have some parameters that I want to POST form-encoded to my server:
{
'userName': 'test@gmail.com',
'password': 'Password!',
'grant_type': 'password'
}
I'm sending my request (currently without parameters) like this
var obj = {
…

texas697
- 5,609
- 16
- 65
- 131
251
votes
3 answers
What are the differences between application/json and application/x-www-form-urlencoded?
What is the difference between
request.ContentType = "application/json; charset=utf-8";
and
webRequest.ContentType = "application/x-www-form-urlencoded";

Prithvi Raj Nandiwal
- 3,122
- 3
- 22
- 34
72
votes
2 answers
How can I remove default headers that cURL sends?
Curl by default adds headers such as Content-type and User-agent. Normally that is a good thing but I'm trying to test what our server does when those headers are missing.
My problem is with the Content-type header. If it is missing, the server…

Jilles van Gurp
- 7,927
- 4
- 38
- 46
20
votes
6 answers
How to post x-www-form-urlencoded in Flutter
I am trying to send a POST request to an API to create an account.
The request is working well, it should look like this :
Bulk Edit Mode :
Key-Value Edit mode :
There are also 9 headers that are auto-generated, so I did not show them, but I can…

Mathieu
- 1,435
- 3
- 16
- 35
10
votes
1 answer
PYTHON: requests.post() how to send request_body encoded as application/x-www-form-urlencoded
I'm doign an app with the Spotify API. My problem is I'm trying to get an access_token but It's not working. In the docs it says i need to send the body encoded as application/x-www-form-urlencoded so I search a little bit and It should work just…

Aldair CB
- 135
- 1
- 1
- 6
8
votes
3 answers
Can AWS API Gateway support `application/x-www-form-urlencoded` with body and query string parameters?
Numerous services can accept query string parameters in the URL when a POST request is made with Content-Type: application/x-www-form-urlencoded and other parameters in the body, but it seems AWS API Gateway cannot while also accepting query string…

Grokify
- 15,092
- 6
- 60
- 81
5
votes
1 answer
TS/playwright - how to post api request with x-www-form-urlencoded body?
I need to create playwright API request with x-www-form-urlencoded body:
Example from postman:
working postman request example
I was trying to it that way:
async getNewApiAccesToken({request})
{
const postResponse = await…

kiwiKiwiKiwi
- 111
- 4
5
votes
0 answers
How to Define Swagger for application/x-www-form-urlencoded Request with Array
I have an API whose curl request is as follows:
curl --request POST \
--url 'http://some.url/api/Resource/findByIds' \
--header 'content-type: application/x-www-form-urlencoded' \
--data 'data[ids][]=100025' \
--data…

muya_
- 768
- 7
- 21
5
votes
4 answers
How to deserialize a x-www-form-urlencoded encoded string in .NET Core 3.1 or .NET Standard?
How to deserialize a x-www-form-urlencoded encoded string in .NET Core 3.1 or in .NET Standard (C#)?
I'm aware of this question - answer. However, FormDataCollection does not appear to be available in .NET Core 3.1. See here.
EDIT: I am being…

bytedev
- 8,252
- 4
- 48
- 56
4
votes
0 answers
drf-spectacular define request content type as 'application/x-www-form-urlencoded'
In drf-spectacular swagger, post method have 3 content types as below
application/json
application/x-www-form-urlencoded
multipart/form-data
Is there anyway to make "application/x-www-form-urlencoded" as default content type for my post…

subba Raidu
- 41
- 3
4
votes
1 answer
How to convert x-www-form-urlencoded to json with Python (Django)
From api i recive x-www-form-urlencoded data.
data = 'leads%5Bstatus%5D%5B0%5D%5Bid%5D=29078079'
when i try to convert it with urllib.parse.parse_qs or urllib.parse.unquote
i got a dict like
{
"leads[status][0][id]": [
"29078079"
…

NaviCross
- 41
- 2
4
votes
1 answer
How to POST to google form by Flutter. The response is always 400 (POSTMAN'S result is 200 OK)
I tried to POST to google form with flutter, but the response is always 400.
When I use POSTMAN, it succeeds.
I cannot understand why it fails with flutter.
I tried http package and dio package, but the result is always 400.
What is the problem? If…

ghffmj
- 291
- 3
- 9
4
votes
2 answers
Convert Json to x-www-form-urlencoded by Postman
I need to know how to Convert The list of object (SERVICES) to x-www-form-urlencoded by Postman
My Json Inputs :
{
"BILLING_NUMBER": "554128536954",
"EVENT_KEY": " BUNDLE",
"PROCCESS_DATE": "",
"LANGUAGE": "EN",
"VERSION": "1",
…

Ahmad Bassam Bkerat
- 95
- 1
- 1
- 8
3
votes
3 answers
Post request with content type application/x-www-form-urlencoded not working in Spring
I'm using OpenAPI generator to generate Spring REST APIs. Here is a fragment:
openapi: 3.0.2
info:
version: 1.0.0
title: Auth
paths:
'/auth/v1/token':
post:
operationId: getAuthToken
requestBody:
content:
…

zolv
- 1,720
- 2
- 19
- 36
3
votes
1 answer
flutter x-www-form-urlencoded POST request
I'm currently trying to send two key values to server and get answer.
My code ( main.dart):
Future createResponsem() async {
Map jsonMap = {
"email":"user",
"pass":"1234"
};
final http.Response…

hhilal
- 163
- 2
- 4
- 17