dummyapi
🛠️

Utilities

4 endpoints

Utility endpoints for generating custom images, identicons, returning mock HTTP status codes, and getting the client IP.

Base URLhttps://dummyapi.codesmash.in/api
GET

Generate a custom PNG image. Params: text, width, height, bg, color, fontSize.

🔗

GET https://dummyapi.codesmash.in/api/image?text=Hello&width=300&height=300

?text?width?height?bg?color?fontSize
fetch('https://dummyapi.codesmash.in/api/image?text=Hello&width=300&height=300')
.then(res => res.json())
.then(console.log);
GET

Generate an identicon PNG avatar from a username string.

🔗

GET https://dummyapi.codesmash.in/api/identicon/:username

fetch('https://dummyapi.codesmash.in/api/identicon/:username')
.then(res => res.json())
.then(console.log);
GET

Return a mock HTTP response with any status code.

🔗

GET https://dummyapi.codesmash.in/api/mock?status=404

?status
fetch('https://dummyapi.codesmash.in/api/mock?status=404')
.then(res => res.json())
.then(console.log);
GET

Returns the client's IP address.

🔗

GET https://dummyapi.codesmash.in/api/ip

fetch('https://dummyapi.codesmash.in/api/ip')
.then(res => res.json())
.then(console.log);
Buy me a coffee