jsonox 🛰 Build Release

CLI based RESTful JSON server + store written in Rust.

Features 🚀

[DISCLAIMER: This program is designed for development purposes. Use in production at your own risk!]

Installation 🔧

You can install in 3 ways: Using pre-compiled binary, from Crate or by manually building from source using rust tool-chain. Give necessary executable permissions for the binary and if building from source.

Pre-compiled Binary

Install from Crate

Or Build From Source

Initial Setup (when installing from binary/source)

Usage 📡

Run the server via the CLI, then setup REST API endpoints or use in Read Only mode.

Command line (CLI)

Note: In the following examples you may need to use ./jsonox if using local binary.

REST API (normal mode)

Construct REST API endpoints on arbitrary routes in the following way(s):

You can also setup your own API by creating files under ./jsonox_data in the structure similar as above:

bash - pets/ - dog/ - index.json - cat/ - index.json - index.json - toys/ - doll/ - index.json

NOTE: POST and PUT are interchangeable and work exactly the same in this mode. This is due to the paths referred to being explicitly specific. To allow for different responses in case of POST and PUT, please consider using the Read Only mode.

Read Only Mode

In this mode, jsonox only reads the json files stored and does NOT create/delete them in case of POST/DELETE unlike in the normal mode explained above. This is useful when you only need to simulate API responses and when your back-end does not strictly follow the REST standards. You can also record the ./jsonox_data in your version control to store your API response structures as it won't change based on the simulations/testing in this mode.