Questions tagged [postman]

Postman is a client for sending and emulating requests over HTTP. It is most commonly used with API requests. Use for questions about the tool itself. Use with any relevant API tags if you are having issues with a specific use.

Started out as a simple testing tool, Postman is now an elegant, flexible tool used to build connected software via APIs - quickly, easily, and accurately. It is used by nearly five million developers and more than 100,000 companies worldwide.

Postman enables you to:

  • Create Collections of requests
  • Organize your work within different Workspaces
  • Split-stack development with Mock Servers
  • Use Tests & Scripts to add dynamic parameters
  • Automate tests with Collection Runner
  • Test performance & behavior with Monitors
  • Document & Publish Collections for collaboration
12313 questions
3256
votes
15 answers

Why does my JavaScript code receive a "No 'Access-Control-Allow-Origin' header is present on the requested resource" error, while Postman does not?

Mod note: This question is about why XMLHttpRequest/fetch/etc. on the browser are subject to the Same Access Policy restrictions (you get errors mentioning CORB or CORS) while Postman is not. This question is not about how to fix a "No…
Mr Jedi
  • 33,658
  • 8
  • 30
  • 40
625
votes
10 answers

Converting a Postman request to curl

I am calling my Java webservice (POST request) via Postman in the following manner which works perfectly fine (i.e. I can see my records getting inserted into the database): And, here's how the contents inside the Headers(1) tab look like: Instead…
Coder
  • 6,381
  • 2
  • 9
  • 10
424
votes
24 answers

How to upload a file and JSON data in Postman?

I am using Spring MVC and this is my method: /** * Upload single file using Spring Controller. */ @RequestMapping(value = "/uploadFile", method = RequestMethod.POST) public @ResponseBody ResponseEntity>…
Harikrishnan K.N.
  • 4,560
  • 2
  • 17
  • 28
419
votes
31 answers

req.body empty on posts

All of a sudden this has been happening to all my projects. Whenever I make a post in nodejs using express and body-parser req.body is an empty object. var express = require('express') var bodyParser = require('body-parser') var app =…
Joseph Dailey
  • 4,735
  • 2
  • 15
  • 18
386
votes
12 answers

Simulate a specific CURL in PostMan

I am using Postman to test some Curl requests to an API server. The API developers gave us the curl command, but I can't send it from the Postman. How to make such a request from the Postman? curl -X POST…
Marin Bînzari
  • 5,208
  • 2
  • 26
  • 43
346
votes
5 answers

Postman Chrome: What is the difference between form-data, x-www-form-urlencoded and raw

I am using the Postman Chrome extension for testing a web service. There are three options available for data input. I guess the raw is for sending JSON. What is the difference between the other two, form-data and x-www-form-urlencoded?
Rohan
  • 13,308
  • 21
  • 81
  • 154
335
votes
16 answers

Postman: How to make multiple requests at the same time

I want to POST data from Postman Google Chrome extension. I want to make 10 requests with different data and it should be at the same time. Is it possible to do such in Postman? If yes, can anyone explain to me how can this be achieved?
user3384231
  • 3,641
  • 2
  • 18
  • 27
318
votes
5 answers

How to download excel (.xls) file from API in postman?

I have an API endpoint and an Authorization token for that API. The said API is for .xls report download. How can I view the downloaded .xls file using (if possible) Postman? If it is not possible using Postman what are the other programmatic ways I…
axnet
  • 5,146
  • 3
  • 25
  • 45
266
votes
33 answers

"Could not get any response" response when using postman with subdomain

I am using postman to test an API I have, all is good when the request does not contain sub-domain, however when I add a sub-domain to URL I am getting this response. Could not get any response There was an error connecting to…
Yahya Hussein
  • 8,767
  • 15
  • 58
  • 114
261
votes
10 answers

How to send Basic Auth with axios

I'm trying to implement the following code, but something is not working. Here is the code: var session_url = 'http://api_address/api/session_endpoint'; var username = 'user'; var password = 'password'; var credentials =…
Emmanuel
  • 2,957
  • 3
  • 14
  • 17
245
votes
8 answers

How to export specific request to file using postman?

I want to export one specific request from a Postman extension (Chromium) and send it to another developer so that they can import it. How I can do this?
Sild
  • 3,077
  • 3
  • 15
  • 21
239
votes
15 answers

How can I use Guzzle to send a POST request in JSON?

Does anybody know the correct way to post JSON using Guzzle? $request = $this->client->post(self::URL_REGISTER,array( 'content-type' => 'application/json' ),array(json_encode($_POST))); I get an internal server error…
user3379466
  • 3,087
  • 2
  • 14
  • 12
219
votes
8 answers

Postman - How to see request with headers and body data with variables substituted

I am using the Postman Chrome plugin to invoke HTTP requests for software testing. I use the Environments feature with Environment and Global Variables to substitute variables in my requests headers and body. The variable substitution is working…
MattG
  • 5,589
  • 5
  • 36
  • 52
219
votes
13 answers

Sending JWT token in the headers with Postman

I'm testing an implementation of JWT Token based security based off the following article. I have successfully received a token from the test server. I can't figure out how to have the Chrome POSTMAN REST Client program send the token in the…
Diode Dan
  • 4,801
  • 6
  • 25
  • 34
213
votes
8 answers

How to import Swagger APIs into Postman?

Recently I wrote restful APIs with SpringMvc and swagger-ui(v2). I noticed the Import function in Postman: So my question is how to create the file which Postman needed? I am not familiar with Swagger.
Demon Coldmist
  • 2,560
  • 2
  • 13
  • 21
1
2 3
99 100