HackerTrans
トップ新着トレンドコメント過去質問紹介求人

tiempie

no profile record

投稿

Show HN: Mocking APIs by just posting jsons to endpoints

github.com
2 ポイント·投稿者 tiempie·9 か月前·0 コメント

Self-hosted API for CRUD-ing JSON data (for easy data storage)

github.com
3 ポイント·投稿者 tiempie·10 か月前·1 コメント

コメント

tiempie
·9 か月前·議論
Nice. So sending {"username": "tom"} to /api/test/users will create > test.json with {"users": {"username": "tom"}} ?
tiempie
·10 か月前·議論
Note, the API is written in GO and 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. Great for personal projects!

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