We may earn an affiliate commission when you visit our partners.
Course image
Artem Bondar

Master API testing using Microsoft Playwright and build production-ready automation frameworks that will set you apart in the competitive QA market. This comprehensive course takes you from complete beginner to confident API testing expert, regardless of your current programming experience.

Complete Learning Path - No Prerequisites Required

Foundation Building (Perfect for Beginners):

Read more

Master API testing using Microsoft Playwright and build production-ready automation frameworks that will set you apart in the competitive QA market. This comprehensive course takes you from complete beginner to confident API testing expert, regardless of your current programming experience.

Complete Learning Path - No Prerequisites Required

Foundation Building (Perfect for Beginners):

  • Master JavaScript and TypeScript fundamentals from scratch in under 2 hours

  • Understand how APIs work and why testing them is crucial

  • Write your very first API tests using Playwright's powerful built-in tools

  • Learn to interact with You'll understand not just the "how" but the "why" behind effective API testing strategies. Most importantly, you'll have the confidence and skills to tackle any API testing challenge in your professional environment.

Enroll now

What's inside

Learning objectives

  • What is api, how does it work, and how to interact with apis
  • How to perform get, post, put, and delete requests using built-in playwright tools.
  • How to make validation of json response object
  • How to efficiently manage and organize your tests to scale
  • How to build a framework using a "fluent interface design" to improve the api scripting experience
  • How to improve reporting and error handling with additional log output
  • What is json schema, how to make schema validation, and how to generate it automatically
  • How to use ai and copilot agent to speed up api scripting development
  • How to create customized assertions

Syllabus

Introduction
Test Application Ovwerview
Configuration of Development Environment
Playwright Setup
Read more
  • First steps in programming with JavaScript

  • Run your first code

How to create variables and constants, what are the differences between those and data types in JavaScript

Two ways to combine several values into a new desired value

How to create objects and arrays. What is the difference between those. Syntax rules. How to read data from an object or array. How to update/replace data in an object or array.

Introduction to different types of relational (comparison) and equality operators. How do they work.
These operators are often used in building the logic of the execution flow

Logical "AND", "OR" and "NOT" operators. How to use them in the execution flow with examples.

The flow control of the code execution with if/else conditional statement

How to repeat the code execution based on the desired condition. This is what the "loops" are for.

Create reusable components of your code using functions. Declarative functions, anonymous functions, and arrow functions. How to parametrize functions and pass an argument into a function. How to return the result of the function. How to export/import functions.

An alternative way of abstraction (code reusability) using classes and methods in JavaScript

  • What is an API, and how does it work

  • API method types such as POST, PUT, GET and DELETE

  • API error status codes

  • How to use Postman to test APIs

  • How to perform exploratory testing of APIs

  • How to debug APIs in Postman

  • How to make a GET request in Playwright

  • How to validate the status code of the response

  • How to read the response object

  • How to make a POST request in Playwright

  • How to validate the status code of the response

  • How to make an authorized post request

  • How to use authorization headers

  • How to get the access token value from the API response

  • How to make a Delete request in Playwright

  • How to make a validation of the deleted property

  • How to make a Put request in Playwright

  • How to reuse the properties of the previous response to make an update request

  • What is test hooks in Playwright

  • Before and After hooks

  • BeforeEach and AfterEach hooks

  • Best practices of using hooks

  • How to execute API tests in Playwright

  • CLI commands to run playwright tests

  • Run tests using VS Code extension

Summary of the section before moving to the next one.

  • What is fluent interface design

  • Creation of the Request Handler class

  • Initial mock-up of the helper methods

  • What are Test Fixtures in Playwright

  • Setup of API test fixture

  • Setting up a URL builder that will be responsible for constructing of request URL

  • Adding the constructor to the Request Handler class

  • Building the right structure to pass the request fixture and API base URL

  • Creation of a custom GET requester within the Request Handler to manage GET API requests

  • Creation of Post, Put and Delete request custom methods within Request Handler

  • Creation of a custom logger class to automatically generate and add execution logs to the Playwright HTML report

  • Creation of the status code validator to capture network logs on status code failure

  • Adding custom assertions, expanding the expect() assertions method to attach logs of the network activity to the reporter when the test fails.

  • Creation of a separate configuration file for API testing

  • Environments management

  • Environment variables for API testing

  • Improving the logic of the request handler, to clean up fields between requests, to make sure no concurrency issues in parallel execution

  • Creation of the helper function to handle access token creation

  • What is a playwright worker, and how to configure it

  • Different worker scopes

  • Configuring the automatic authorization for the test run as a default framework setup

  • Adding an option to the Request Handler to perform unauthorized requests when needed

  • Properties of the Playwright configuration file

  • Dependencies between the global scope and the project scope

  • How to configure Playwright for API automation

  • Adding test.step() method into the request handler to hide redundant steps from the reporter and improve reporter readability.

  • What is JSON schema, and what is the structure of the schema format

  • Creation of the schema validator class

  • Reading the JSON schema from a file

  • Creation of schema validator method using AJV

  • Creation of a custom assertion shouldMatchSchema() method for the schema validations

  • How to generate JSON schema automatically based on the API response and save it into a file

  • How to use AJV formats for assertion of the specific data formats in the JSON schema

  • How to organize and manage a JSON object with a request payload within the project

  • How to run the same test multiple times with a different dataset

  • How to run negative test cases efficiently

  • When you need detailed network information about requests and responses to debug test scenario, this is where you find it

  • How to manage environment variables in API testing

  • How to switch between different environments such as DEV, QA, PROD

  • How to organize Playwright UI and API automation in a single framework to make sure you will not have concurrency issues

  • How to run UI and API tests together or sequentially, slicing the scope by projects

  • How to set up Copilot in VS Code

  • Overview of how Copilot code completion works, its pros and cons

  • What is Copilot Ask mode

  • Explanation of the AI context window and how to add information to the AI context

  • How to use Copilot Agent to speed up framework maintenance, for example, update assertions for the tests.

  • How to use Copilot Agent to automatically generate new test assertions and automatically debug and fix failed tests

  • How to organize and manage Copilot instructions and prompts properly.

  • How to use AI and Copilot Agent to quickly write the code, adding new custom features. Let AI to do a heavy lift

  • How to convert UI tests into API tests with the help of AI

Save this course

Create your own learning path. Save this course to your list so you can find it easily later.
Save

Activities

Coming soon We're preparing activities for Playwright API Testing Mastery with TypeScript. These are activities you can do either before, during, or after a course.

Career center

Learners who complete Playwright API Testing Mastery with TypeScript will develop knowledge and skills that may be useful to these careers:

Reading list

We haven't picked any books for this reading list yet.
Provides a comprehensive overview of API testing, covering topics such as test design, execution, and automation. It is written by a leading expert in API testing and is considered one of the best books on the subject.
Practical guide to API testing using Selenium, a popular web testing tool. It is written by an experienced API testing expert and great resource for anyone who wants to learn how to use Selenium for API testing.
Practical guide to API testing using Postman, a popular API testing tool. It is written by an experienced API testing expert and great resource for anyone who wants to learn how to use Postman for API testing.
Practical guide to API testing using RestAssured, a popular Java library for API testing. It is written by an experienced API testing expert and great resource for anyone who wants to learn how to use RestAssured for API testing.
Practical guide to API testing using Cucumber, a popular API testing tool. It is written by an experienced API testing expert and great resource for anyone who wants to learn how to use Cucumber for API testing.
Explores behavior-driven development (BDD) with Playwright and Java, offering strategies for writing maintainable and expressive tests.
Offers practical recipes for solving common challenges in web automation using Playwright. It covers a wide range of topics, including handling dynamic content, testing AJAX requests, and working with different web frameworks.
Provides best practices and design patterns for writing effective and maintainable Playwright tests, ensuring reliability and scalability.
This beginner-friendly guide to TypeScript provides a step-by-step introduction to the language, making it a great choice for those who are new to TypeScript.
This practical guide to TypeScript provides a comprehensive overview of the language, making it a great choice for developers of all levels.
This concise guide to TypeScript provides a quick and easy introduction to the language, making it a great choice for developers who want to get up to speed on TypeScript quickly.
This hands-on guide to TypeScript provides a practical introduction to the language, making it a great choice for developers who want to learn how to use TypeScript in real-world projects.
This beginner-friendly guide to TypeScript provides a step-by-step introduction to the language, making it a great choice for those who are new to TypeScript.
This practical guide to TypeScript provides a comprehensive overview of the language, making it a great choice for developers of all levels.
Covers the principles and practices of software testing, including test automation. It comprehensive guide for both testers and developers who want to learn more about test automation.
This practical guide to TypeScript for Node.js developers provides a comprehensive overview of the language, making it a great choice for developers who want to use TypeScript with Node.js.
This practical guide to TypeScript for Angular developers provides a comprehensive overview of the language, making it a great choice for developers who want to use TypeScript with Angular.
Covers the principles and practices of software test automation. It comprehensive guide for both testers and developers who want to learn more about test automation.
This practical guide provides 62 specific tips and tricks for writing better TypeScript code, making it a valuable resource for developers of all levels.
Comprehensive guide to JavaScript, covering all the basics for beginners. It is well-written and easy to follow, making it a great starting point for anyone who wants to learn JavaScript.

Share

Help others find this course page by sharing it with your friends and followers:

Similar courses

Similar courses are unavailable at this time. Please try again later.
Our mission

OpenCourser helps millions of learners each year. People visit us to learn workspace skills, ace their exams, and nurture their curiosity.

Our extensive catalog contains over 50,000 courses and twice as many books. Browse by search, by topic, or even by career interests. We'll match you to the right resources quickly.

Find this site helpful? Tell a friend about us.

Affiliate disclosure

We're supported by our community of learners. When you purchase or subscribe to courses and programs or purchase books, we may earn a commission from our partners.

Your purchases help us maintain our catalog and keep our servers humming without ads.

Thank you for supporting OpenCourser.

© 2016 - 2025 OpenCourser