Installation
#
Integrate into Existing AppsIf you integrate JSONClasses into an existing app, just install it with pip
.
pip install jsonclasses
Integration packages are also installed with pip.
pip install jsonclasses-pymongopip install jsonclasses-server
#
A JSONClasses ServerIf you create a JSONClasses app and get the free automatic RESTful CRUD routes, this is the coolest. Follow this guide with the great CLI tool, you can create a running server under several minutes.
#
Create a Virtual EnvCreate a new directory and setup Python's virtual env inside of it.
mkdir first-projectcd first-projectpython3.10 -m venv .venvsource .venv/bin/activate
#
Generate Starter CodeInstall JSONClasses CLI by typing this command.
pip install jsonclasses-cli
With JSONClasses CLI, we can easily create a new project.
jsonclasses new .
The CLI tool will prompt you for some answers, just press return
or enter
to use the default option.
#
Run the ServerAfter the project is setup, type flask run
to run the generated app. A server
is running and waiting for your HTTP requests now.