screen size not supported

How to use it

DummyJSON can be used with any type of front end project that needs products, carts, users, todos or any dummy data in JSON format.

You can use examples below to check how DummyJSON works.

Feel free to enjoy it in your awesome projects!

Intro

Limiting Resources

All the resources can be used with query params to achieve pagination and get limited data.

              
fetch('https://dummyjson.com/RESOURCE/?limit=10&skip=5&select=key1,key2,key3');
            
           

OR

              
fetch('https://dummyjson.com/RESOURCE/?limit=10&skip=5&select=key1&select=key2&select=key3');
            
           

Authorizing Resources

All resources can be accessed via an authentication token to test as a logged-in user.
Go to auth module and generate an auth token to get data as an authorized user

              
/* providing token in bearer */
fetch('https://dummyjson.com/auth/RESOURCE', {
  method: 'GET', /* or POST/PUT/PATCH/DELETE */
  headers: {
    'Authorization': 'Bearer /* YOUR_TOKEN_HERE */', 
    'Content-Type': 'application/json'
  }, 
})
.then(res => res.json())
.then(console.log);
            
           
Auth Products