{"id":15288715,"url":"https://github.com/anergictcell/pyhpoapi","last_synced_at":"2025-04-13T08:10:13.698Z","repository":{"id":50769909,"uuid":"339077705","full_name":"anergictcell/pyhpoapi","owner":"anergictcell","description":"A REST-API wrapper around PyHPO to handle the Human Phenotype Ontology (HPO) through HTTP(S)","archived":false,"fork":false,"pushed_at":"2023-07-28T19:55:25.000Z","size":84,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-13T08:09:55.019Z","etag":null,"topics":["fastapi","hpo","hpo-explorer","hpo-similarity","python","rest-api"],"latest_commit_sha":null,"homepage":"https://github.com/Centogene/pyhpoapi","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/anergictcell.png","metadata":{"files":{"readme":"README.rst","changelog":"CHANGELOG.rst","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-02-15T12:55:07.000Z","updated_at":"2023-08-09T19:56:54.000Z","dependencies_parsed_at":"2024-03-03T12:54:07.308Z","dependency_job_id":null,"html_url":"https://github.com/anergictcell/pyhpoapi","commit_stats":null,"previous_names":["anergictcell/pyhpoapi"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anergictcell%2Fpyhpoapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anergictcell%2Fpyhpoapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anergictcell%2Fpyhpoapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anergictcell%2Fpyhpoapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/anergictcell","download_url":"https://codeload.github.com/anergictcell/pyhpoapi/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248681491,"owners_count":21144700,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fastapi","hpo","hpo-explorer","hpo-similarity","python","rest-api"],"created_at":"2024-09-30T15:52:27.222Z","updated_at":"2025-04-13T08:10:13.674Z","avatar_url":"https://github.com/anergictcell.png","language":"Python","readme":"*********\nPyHPO-API\n*********\n\nA HTTP REST-API wrapper for `PyHPO`_\n\nMain features\n=============\nThis package allows an easy setup of a REST API to interact with HPO Terms using the `PyHPO`_ package.\n\n\nAPI Documentation\n=================\nTo see an interactive API documentation, install PyHPO-API, run the app and visit http://127.0.0.1:8000/docs\n\n\nInstallation / Setup\n====================\n\nThe easiest way to install PyHPO-API is via pip\n\n.. code:: bash\n\n    pip install pyhpoapi\n\n\n.. note::\n\n    **PyHPO-API** ships with ``pyhpo`` as the underlying Ontology by default. it is also possible to use `hpo3 \u003chttps://pypi.org/project/hpo3/\u003e`_ instead. ``hpo3`` is a drop-in replacement of ``pyhpo`` written in Rust and is much faster. It is not 100% feature complete, so use it with caution. To switch to ``hpo3`` unintstall pyhpo and then install hpo3\n\n    .. code:: bash\n\n        pip uninstall -y pyhpo\n        pip install hpo3\n\n\nUsage\n=====\n\nGetting started\n---------------\nThe easiest way to get started is to run the API via\n\n.. code:: bash\n\n    uvicorn pyhpoapi.main:app\n\n\nParallel processing\n-------------------\nIf you want better performance for parallel request handling,\nyou can run PyHPO-API with multiple workers\n\n.. code:: bash\n\n    uvicorn pyhpoapi.main:app --workers 15 \n\n\n.. note::\n\n    Don't use more workers than available CPUs as it will backfire\n    and slow down processing due to constant context-switches\n\nCORS\n----\nIf you need to allow cross-origin requests, you specify CORS settings through environment variables::\n\n    export PYHPOAPI_CORS_ORIGINS=\"*\"\n    export PYHPOAPI_CORS_METHODS=\"GET,POST\"\n    export PYHPOAPI_CORS_HEADERS=\"*\"\n\n\nDev\n===\n\nGetting started for development\n-------------------------------\nClone the repository\n\n.. code:: bash\n\n    git clone https://github.com/anergictcell/pyhpoapi.git\n    cd pyhpoapi\n\n\nUse Docker for development\n--------------------------\nOne way to do this is to run a docker container during development\n\n.. code:: bash\n\n    docker run --rm -v $(pwd):/src -p 8000:8000 -it python:3.9-slim-buster bash\n\n    cd src\n    pip3 install -r requirements.txt\n    pip3 install -r requirements-dev.txt\n\n    python3 -m unittest discover tests\n\n    uvicorn --host 0.0.0.0 --reload pyhpoapi.main:app\n\n\nOr local development without Docker\n-----------------------------------\n\nCreate a virtual environment and install requirements in the virtual environment\n\n\n.. code:: bash\n\n    virtualenv venv_pyhpoapi\n    source venv_pyhpoapi/bin/activate\n\n    pip3 install -r requirements.txt\n    pip3 install -r requirements-dev.txt\n\n    python3 -m unittest discover tests\n\n    uvicorn --reload pyhpoapi.main:app\n\n\n.. _PyHPO: https://github.com/Centogene/pyhpo\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanergictcell%2Fpyhpoapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanergictcell%2Fpyhpoapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanergictcell%2Fpyhpoapi/lists"}