Docs
You can use examples below to check how DummyJSON works.
Mock HTTP
Mock HTTP Response
You can mock and test any HTTP responses. You may test each
individual HTTP code by visiting:
dummyjson.com/{code}/{optional-message}
Show outputfetch('https://dummyjson.com/http/200') .then(res => res.json()) .then(console.log);
Custom HTTP Response
Show outputfetch('https://dummyjson.com/http/404/Hello_Peter') .then(res => res.json()) .then(console.log);