API Mocking made easy

Create fully mocked APIs quickly—with realistic, randomised data and customisable responses for faster, more reliable testing with fewer blockers

    • Jose Carrera's profile
  • Intermediate
  • 3
  • 3
  • 10
What is API mocking and when should you use it?
  • Explain what API mocking is and how it supports testing
  • Recognise common challenges in integration testing that mocking can help mitigate
  • Analyse integration points in a system to identify where mocking an API would be valuable
Getting started with API mocking using Mockoon
  • Install and run Mockoon on your local machine
  • Explore Mockoon’s interface and key features
  • Compare Mockoon to other API mocking tools based on functionality and ease of use
Capturing API requests and creating your first mock responses
  • Set up and run the MERN test application locally
  • Create a mocked endpoint from scratch through the UI
  • Setup a proxy connection from mockoon
  • Mock an endpoint in one click from the application logs

Writing reliable and fast UI (E2E) tests can be a challenge, even with advanced testing frameworks. A common pain point is how tests interact with external APIs, which are often slow, unreliable, or flaky. That's where mocking APIs comes in handy.

By mocking specific APIs, we can make our UI tests run smoother and faster. In this course, you’ll learn how to do just that using Mockoon: a free, open-source tool that requires no coding skills and can be set up in minutes.

We'll dive into Mockoon's main features, from the basics to useful options like proxying requests, using variables, and debugging mock environments.

Since no coding is required, you can use Mockoon at various testing levels, from automated UI checks to exploratory testing sessions.

Through hands-on lessons and practical examples, you’ll learn to create realistic and reusable mock APIs that can simplify your testing workflow and speed up feedback loops in your projects.

By the end of this course, you'll be able to:

  • Set up and use Mockoon for mocking APIs at different stages of testing
  • Simulate various API behaviours including delays, status codes, and errors
  • Use dynamic and randomised data in mock responses
  • Integrate mocks into your automated UI tests and CI pipelines
  • Version and maintain your mocks with Git
  • Basic understanding of web applications
  • Access to GitHub and node installed (desired)

 

Leave Complexity Behind image
No-Code Test Automation with Low-Code integration via Robot Framework and TestBench
Explore MoT
Leading with Quality image
Tue, 30 Sep
A one-day educational experience to help business lead with expanding quality engineering and testing practices.
MoT Foundation Certificate in Test Automation image
Unlock the essential skills to transition into Test Automation through interactive, community-driven learning, backed by industry expertise
Leading with Quality
A one-day educational experience to help business lead with expanding quality engineering and testing practices.
This Week in Testing image
Debrief the week in Testing via a community radio show hosted by Simon Tomes and members of the community
Senior QA Consultant
José Carréra is from Brazil, where he graduated in computer science in 2007 and completed his masters in 2009. Professionally, he has been working on quality related roles since 2006. Moved to the UK in 2015, where currently works as a Senior QA consultant at Ensono Digital.
Subscribe to our newsletter
We'll keep you up to date on all the testing trends.