No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Maxime Alves LIRMM@home cd0df35496 [tests][lib/responses] format des dates ORJSON + update deps (fix bug dates) 1 month ago
conf [release][0.1.0] First HalfAPI release 8 months ago
halfapi [debug] ajout des routes /error/{code:str} et /exception 1 month ago
scripts [query] add fields list to query 8 months ago
tests [tests][lib/responses] format des dates ORJSON + update deps (fix bug dates) 1 month ago
.gitignore [router][api] Fix GET / 6 months ago
CHANGELOG.md [release][0.1.0] First HalfAPI release 8 months ago
LICENSE [release][0.1.0] First HalfAPI release 8 months ago
MANIFEST.in [package] fixed some paths 7 months ago
Pipfile [tests][lib/responses] format des dates ORJSON + update deps (fix bug dates) 1 month ago
Pipfile.lock [tests][lib/responses] format des dates ORJSON + update deps (fix bug dates) 1 month ago
README.md [doc] Update readme 8 months ago
pyproject.toml [deps] Updated dependencies and added files for standard packaging. 8 months ago
pytest.ini [routing] handle fqtn parameter in domain schema + get_api_routes (/) + /user -> /halfapi/current_user 6 months ago
requirements.txt [deps] removed half_orm from dependencies 5 months ago
setup.cfg [deps] Updated dependencies and added files for standard packaging. 8 months ago
setup.py [update] fixage des versions des dépendances, fixage de python >= 3.7 2 months ago

README.md

HalfAPI

This Python-based ASGI application aims to provide the core functionality to multiple API domains.

It’s developed at the LIRMM in Montpellier, France.

The name “halfAPI” comes from the deep relationship between it and halfORM, a project authored by Joël Maizi.

You’ll need a database with the API details. You can find the database model in halfapi/models/api.sql

TODO : include a token generation tool for testing purpose.

Dependencies

  • python3
  • python3-pip
  • libgit2-dev

Installing

With local folder :

pip3 install -r requirements.txt .[cli]

From the repository :

pip3 install git+ssh://git@gite.lirmm.fr:malves/halfapi.git[cli]

CLI usage

Running

Development mode

In the project’s folder :

halfapi run

Production

The production server may use different init systems. As our main server is Debian-based, we use systemd services to manage the api server. Find the right service files and configure them properly in order to make your production setup perfect.

cp conf/systemd/lirmm_api* /etc/systemd/system/
systemctl daemon-reload
systemctl start lirmm_api

To make it start at boot :

systemctl enable lirmm_api

To get the logs :

journalctl -f --unit lirmm_api

Testing

Installing

pip3 install .[cli][tests]

Running

pytest -v