Skip to main content

Set up a modern REST API by running one command.

Project description

FastApi Gen

Create FastAPI apps with no build configuration.

FastApi Gen works on macOS and Linux.
If something doesn’t work, please file an issue.

Available templates:

  1. Default - basic template with GET/POST examples.
  2. Nlp - natural language processing template with examples how to use Hugginface summarization, named-entity recognition and text generation using LLM.

More to come!

Quick Overview

pip3 install fastapi-gen
fastapi-gen my_app
cd my_app
make start-dev

or

pipx run fastapi-gen my_app
cd my_app
make start-dev

If you've previously installed fastapi-gen globally via pip3 install fastapi-gen, we recommend you reinstall the package using pip3 install --upgrade --force-reinstall fastapi-gen or pipx upgrade fastapi-gen to ensure that you use the latest version.

Then open http://localhost:8000/docs to see your app OpenAPI documentation.

Get Started Immediately

You don’t need to install or configure depencendeices like FastApi or Pytest.
They are preconfigured and hidden so that you can focus on the code.

Create a project, and you’re good to go.

Creating an App

You’ll need to have Python 3.7+ or later version on your local development machine. We recommend using the latest LTS version. You can use pyenv (macOS/Linux) to switch Python versions between different projects.

basic template

pip3 install fastapi-gen
fastapi-gen my_app

or

pip3 install fastapi-gen
fastapi-gen my_app --template hello_world

NLP template

pip install fastapi-gen
fastapi-gen my_app --template nlp

Inside the newly created project, you can run some built-in commands:

make start

Runs the app in development mode.
Open http://localhost:8000/docs to view OpenAPI documentation in the browser.

The page will automatically reload if you make changes to the code.

make test

Runs tests.
By default, runs tests related to files changed since the last commit.

License

fastapi-gen is distributed under the terms of the MIT license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fastapi_gen-0.2.0.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

fastapi_gen-0.2.0-py3-none-any.whl (15.5 kB view details)

Uploaded Python 3

File details

Details for the file fastapi_gen-0.2.0.tar.gz.

File metadata

  • Download URL: fastapi_gen-0.2.0.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for fastapi_gen-0.2.0.tar.gz
Algorithm Hash digest
SHA256 8d9625f88ce98e198d27f4a122d802e9112498866a147dd77c32f876b4f58285
MD5 b0c0132450fdc57050f7dc93f97cac75
BLAKE2b-256 278e0cd3aeec8defdb7545f38a1fad469a8b163d447dff6108c87a7d758e3f2a

See more details on using hashes here.

File details

Details for the file fastapi_gen-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: fastapi_gen-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 15.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for fastapi_gen-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3235777e853d5f235f72b3b29f620dec465c54a42d3bd64ba3b898079a365897
MD5 c8bb41e87a3456ec953f5c30fcd1f942
BLAKE2b-256 809b2ba894487ae15bf4ef55a8b22de5fa466a12a68bd9781c45f108d1f6d400

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page