
This course includes our updated coding exercises so you can practice your skills as you learn.
See a demo
In this lecture, I wanted to give you an overview of the entire course.
Postman collections allow you to organize and group your API requests in a way that makes them easy to find, use, and share with others.
A Postman collection is a group of requests. Each request in a collection has its own set of properties, such as the request method, URL, and headers. You can also add documentation and test scripts to each request, which can be useful for testing and debugging your API.
Learn to view API responses in Postman using pretty, raw, and collapse to read JSON with color syntax and collapsible sections; compare raw versus pretty and preview HTML examples.
Explore filtering products by category with query parameters in the api. See how using dairy retrieves dairy items and how 200 and 400 responses reflect input validity; Postman manages parameters.
Learn how API parameters and query parameters work in Postman, focusing on the get products endpoint; only supported parameters affect results, per the API documentation.
Study the API documentation, add the results query parameter to your request, and disable a category to test effect. Try values, observe behavior, and identify bugs ahead of the quiz.
Investigate how the query parameter results control the number of products returned, default 20, with category filtering and invalid values; discuss pagination limitations with the development team.
Learn how path variables work in rest apis by using the endpoint /products/{productId} to fetch a single product in Postman, and distinguish path parameters from query parameters.
Identify path variables and query parameters. Follow api documentation to know which are mandatory or optional, and remember path variables come before the question mark; query parameters come after.
Study the api documentation to use the get cart and get cart items endpoints in Postman. Verify the cart returns status 200 and an empty items list.
Demonstrate posting a JSON body to add a cart item, using the card id in the path and product id in the body, and observe 400 and 201 responses.
Practice placing an order by building and testing the request, guided by a step-by-step quiz. Study the API documentation and experiment with the API before viewing the solution.
Postman automatically manages HTTP headers, including content-type as application/json; learn to view and override headers like authorization by redefining them, and understand duplicate and inherit auth behavior.
Apply a patch request to update an order by its order ID with bearer authorization, then fetch all orders to confirm the customer name is Joe Doe.
Learn how to perform a patch request in Postman to update only the comment on an order, leaving the customer name unchanged, with a 204 no content response.
Demonstrate updating a cart item quantity with a patch request using cart ID and item ID, sending a quantity in the body, and observing a 204 no content response.
Use a put request to replace a cart item by supplying cartId and itemId in the path and a new productId in the body, updating the entire item.
Learn how to delete an item from a cart using the HTTP delete method in Postman, including sending no body and handling a 204 no content response.
Practice building and testing APIs with Postman by guiding Trello boards, lists, and tasks through hands-on steps, embracing mistakes to master REST API testing.
Learn to work with real-world APIs by using Trello's API through Postman, creating boards, lists, and tasks, and comparing UI actions with underlying API calls.
Learn to navigate public API documentation, identify resources like boards, and perform a simple POST to create a board at api.trello.com/1/boards using a key and token.
Follow the api documentation to authenticate via key and token as query params, avoid spaces, save requests in a collection, and use proper post requests to create boards.
Learn to create a new list on a board with a POST request to the lists endpoint, supplying name and idBoard, and validating the returned list ID.
Learn to create a new card via the cards endpoint with a POST request, provide the card name and required ID list, and see how lists and boards relate.
Explore how to move a Trello card through the REST API by treating it as a resource, performing create, delete, or update operations, and verify the result on Trello.com.
Learn JavaScript basics to unlock Postman for API tests and advanced testing, and avoid confusing JavaScript with Java.
Define JavaScript variables in Postman scripts with var, label them like FirstName and Age, and use console.log to verify values while noting variables are temporary and not stored by Postman.
Use let instead of var to define variables in modern JavaScript and avoid reliability issues. Understand undefined when a value isn't set, and how quotes distinguish strings from numbers.
Master JavaScript variable naming by using camelCase and snake_case, choosing descriptive names, preferring is/has prefixes for booleans, avoiding abbreviations, and respecting case sensitivity for readable code.
Define constants with const to keep values unchanged during code execution, such as a website url or the seconds in a day, and switch to let if reassignment is needed.
Learn how to define a function add with parameters a and b, call it with arguments, and use return to produce the sum, using console.log and backticks for template strings.
Explore built-in JavaScript functions, generate random numbers with Math.random, and convert to integers with Math.floor. Create reusable getRandomNumber functions using a maxValue parameter.
Objects gain behavior through methods, which are functions attached to the object. Call a method with parentheses to execute it, as sayHello returns value when invoked on the person object.
Apply square bracket notation instead of dot notation with quoted property names like 'first-name' or 'e-mail' to access or set object properties that include spaces or dashes.
Learn to access items in arrays and nested objects using zero-based indices, square bracket notation, and dot notation, including the TikTok handle in socialProfiles.
In this section, we are going to start writing basic tests and assertions in Postman using JavaScript and the Postman pm object.
Learn to write status code tests for every request in a Postman collection and ensure tests fail when needed, guided by a step-by-step quiz.
Demonstrates adding status code tests for all collection requests, updates assertions from 200 to 201 as needed, and uses collection variables to validate cart, item, and order endpoints.
Learn to write resilient REST API tests in Postman by asserting data types, such as price as a number above zero and response as an object.
Test api error handling by combining happy path and negative scenarios in Postman, including missing authentication, invalid tokens, and 401 errors, while organizing requests with folders for clarity.
Organize authentication tests by duplicating requests to cover missing header and invalid token scenarios. Reuse tests at folder level to apply status checks across requests, reducing duplication and simplifying maintenance.
organize Postman rest api tests to reduce duplication by moving tests into folder levels, creating missing header and invalid token folders, and enabling folder-level tests for easier maintenance.
Document requests, folders, and collections in Postman by adding detailed descriptions and notes to each request, folder, and the collection to clarify purpose, tests, and expected outcomes.
Learn to automate API testing by setting and reading Postman variables in scripts, eliminating manual data changes and streamlining requests for robust automation.
Master setting Postman collection variables from scripts with the set method, creating or updating variables by key and value. Learn to reference JavaScript variables for dynamic data in your requests.
Apply the fail-fast principle in Postman testing to validate collection variables by guarding against undefined responses, asserting a non-empty array, and verifying product.id and inStock before setting variables.
Store dynamic API data in Postman variables by scripting the item ID from responses and reusing it across requests, and apply same to the order ID with tests for robustness.
Learn how to set and retrieve postman collection variables in scripts using pm.collectionVariables.get and set, and validate them in tests with console.log.
Practice using Postman variables in scripts by writing a test that verifies the response body contains the order ID from a get single order request after deletion.
Use a JavaScript for loop to search the orders array in Postman, with initialization, a condition, and afterthought, and log results with console.log.
Parse get all orders response, iterate over the order array with a for loop, and compare each id to the last submitted orderId from collection variables to verify a match.
Write assertions against an order id in a response array by wrapping code in pm.test, then track a boolean and assert it with pm.expect(...).to.be.true.
Learn to replace forEach with find to locate an order by id in a response array, assert the result is an object, and simplify Postman tests.
learn to use postman variables across the request builder and scripts, including in url, query params, path variables, authorization headers, body, and tests, using pm.collectionVariables.get.
Use test-driven development (TDD) to write tests before code, shaping the interface and documenting requirements. The lecture shows applying API testing with negative inputs and automated tests guiding bug fixes.
Learn to use Postman environments and environment variables to test across multiple servers, switching the base URL between testing and production while understanding precedence with collection variables.
Environments keep production data separate from testing and require environment-specific tokens. Store the accessToken as an environment variable and use the secret option to hide it.
Export and import Postman environments as files, learn that initial values are shared but current values and secrets are not, and add secrets after importing.
Learn how to manage Postman environment variables from scripts using pm.environment.set, pm.environment.get, and pm.environment.unset, and understand the importance of selecting an environment.
Discover how to fetch variables by current scope in Postman scripts with pm.variables.get, automatically resolving collection or environment values and matching the request builder's curly braces syntax.
Migrate collection variables to environment variables by moving baseUrl, accessToken, cartid, lastAddedItemid, and orderid into production and testing environments, and replace pm.collectionVariables.set and pm.collectionVariables.get with pm.environment.set and pm.variables.get.
This lectures explain what are global variables and what is their scope.
Practice what you have learned by applying Postman skills to the Trello API, creating tasks that document functionality, using variables to streamline requests, and writing scripts to handle complex scenarios.
Learn how to use Postman collection variables to store and reuse ids like boardId, todoListId, doneListId, and cardId when testing the Trello API, enabling end-to-end requests with automated checks.
Automate board cleanup by retrieving the first board ID with the get all boards request, storing it in a postman variable named board ID, and executing the delete board request.
Write tests for the create board request to verify creation, check status code, and validate the response body: board name, open state, prefs permission level private, and calendar view disabled.
Demonstrates writing Postman tests to verify created board properties, including name and private status, and uses console logs and find to access the calendar view and assert calendar.enabled is false.
Delete all boards, then create dynamic boards named Learning Postman 1, 2, 3 using a pre-request script that increments a collection variable and handles isNaN initialization.
Test the put request to move a card from the to-do list to the done list, and verify the card's name remains as provided when created.
Learn to write resilient Postman tests that gracefully handle non-json responses, isolate parsing errors, and keep test suites running by encapsulating failures within individual tests.
Short introduction to the Chai JS assertion library used in Postman.
In this lecture we will have a look at an example on how to make assertions on nested JavaScript objects and arrays.
In this lecture we will have a look on how to make assertions on nested JavaScript objects.
Sometimes it is needed to test headers and cookies as well. This lecture deals with that.
In this short lecture I wanted to give you an overview of what you will learn in this entire section.
What we want to achieve is to run the entire collection (one request after another) and to get an overview of successful or failed tests. There are multiple ways to automate things and next I will give you an overview.
The collection runner is included in Postman and facilitates the first step toward automation. It is a useful way to run the entire collection or just a subset of it (by selecting a specific folder) without any other external tools.
Install and use the Postman CLI to run a Trello API collection, log in with an API key, execute the run, and review detailed reports for iterations, requests, and debugging.
Learn Postman with a Postman Supernova.
RESTful APIs (or simply REST API) are everywhere nowadays, but at the same time, they are getting more complex to get started with: different HTTP methods (GET, POST, PUT, PATCH, DELETE), headers, cookies, dealing with file uploads or authentication with API keys, tokens, OAuth and so much more.
This is where the Postman App comes in! Postman allows you very quickly to create a request with the required HTTP method and parameters, submit the request and easily inspect the results.
I have created this course for testing engineers as well as for software developers or other technical positions. Postman can help you during the development of your API, as well as after the API is completed, by running tests that make sure your API is still working as intended.
In the first part of the course, we will start exploring the features of Postman and continue by writing API tests with the intention of integrating them into a CI server where the tests will run on a current basis.
But this is not the normal course you take part in. Because your needs may be different and because I hate leaving you wondering what to do next, the second part of the course will include user questions and answers to problems that were not yet covered in the course or that are more specific and may not interest everybody.
So let’s look at what you are going to learn:
HTTP request methods (GET, POST, PUT, PATCH, DELETE)
JSON format
Start with simple requests and advance toward more complex scenarios
Learn to deal with authentication/authorization mechanisms like Basic Auth, API Keys, or OAuth.
Start writing API tests
Organize tests in collections and share them with your team
Run API tests in Jenkins or any other CI server
You ask, I answer
So after this course, you will know how to use Postman as a pro.
Excited to learn Postman? Join the course today.
Legal Disclaimer
This course is an independent educational resource and is not endorsed by, affiliated with, or associated with Postman, Inc., or any of its products. Postman is a trademark of Postman, Inc. All product names, logos, and brands mentioned in this course are the property of their respective owners.
This course contains promotional materials.