Skip to main content

fetch-mock

fetch-mock is a node.js package which allows developers to simply and easily configure mock API responses. This is useful as it allows development to proceed even if the APIs referenced are not yet available or not accessible. Developers can define declarative matching for most aspects of a HTTP request, including: URL, headers, body and query parameters. Developers can also include delays in responses to simulate real world response times.

More details on the fetch-mock node.js package can be found on the fetch-mock home page;

Reference

fetch-mock is used within the CSA plugin and more information on this is available here:

fetch-mock in the CSA plugin