Settings

Theme

Show HN: Mocking APIs by just posting jsons to endpoints

github.com

2 points by tiempie 3 months ago · 0 comments · 1 min read

Reader

I made a self-hosted API for crud-ing json data (initially for simple storage use cases). However, I started using to mock APIs, where I have scripts that create/edit random jsons and I make them available as API endpoints through this application.

The API is based on your JSON structure. So the example below is for CRUD-ing [key1][key2] in file.json. The value (which can be anything) is then added to the body of the request. Moreover, there are helper functions for appending and incrementing values.

  DELETE/PUT/GET: /api/file/key1/key2/...

No comments yet.

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection