Postman Cheatsheet - API Debugging Tool Reference
All essential Postman commands organized by use case, with 35+ entries you can copy and run directly. Find the right command fast when you need it.
Back to Dev ToolsRequest Building 7
GET {{base_url}}/api/usersGET request
POST {{base_url}}/api/usersPOST request
PUT {{base_url}}/api/users/1PUT request
DELETE {{base_url}}/api/users/1DELETE request
Headers: Content-Type: application/jsonSet a request header
Body → raw → JSONJSON request body
Authorization: Bearer {{token}}Bearer Token auth
Environment Variables 6
{{base_url}}Reference an environment variable
pm.environment.set("token", "xxx")Set an environment variable
pm.environment.get("token")Get an environment variable
pm.environment.unset("token")Unset an environment variable
pm.globals.set("key", "value")Set a global variable
pm.variables.get("key")Get a variable (env/global)
Test Scripts 6
pm.test("Status is 200", () => { pm.response.to.have.status(200) })Status code test
pm.expect(pm.response.json().name).to.eql("Alice")JSON field test
pm.response.to.be.jsonResponse is JSON
pm.response.to.have.header("Content-Type")Response header test
pm.expect(pm.response.responseTime).to.be.below(500)Response time test
const json = pm.response.json()Parse response JSON
Pre-request Scripts 4
pm.request.headers.add({key: "X-Token", value: "xxx"})Dynamically add a request header
pm.request.body.update("new body")Modify the request body
const timestamp = Date.now(); pm.environment.set("ts", timestamp)Generate a timestamp
pm.request.url.addQueryParams({page: 1})Add a query parameter
Collections & Runner 7
Collection RunnerRun a collection in batch
New RunnerNew runner
Set Data File (CSV/JSON)Data-driven testing
Delay: 1000msRequest interval
Iterations: 10Iteration count
Export CollectionExport collection
Import from cURL / OpenAPIImport from cURL / OpenAPI
Mock & Docs 5
Mock ServerCreate a Mock server
Example ResponsesSave example responses
DocumentationGenerate API docs
Publish DocumentationPublish docs
MonitorMonitor
Tips
- Variables come in Environment (current) and Global; put secrets in Environment.
- Collection Runner plus a CSV data file enables data-driven testing.
- Mock Server suits parallel frontend dev when the backend isn't ready yet.
Official References
Commands are compiled from the official docs below. Click to verify the latest usage.
Maintained by LaoHand
Publicly updated on Jul 21, 2026, continuously proofread against official docs.
Contact Us
Wrong command or description? Send us corrections, business inquiries or product feedback by email.
Contact Us