{"id":15020961,"url":"https://github.com/qcri/apihub","last_synced_at":"2026-02-15T10:07:16.018Z","repository":{"id":62995927,"uuid":"370301686","full_name":"qcri/apihub","owner":"qcri","description":"serve and publish API","archived":false,"fork":false,"pushed_at":"2024-06-02T15:03:37.000Z","size":864,"stargazers_count":2,"open_issues_count":2,"forks_count":1,"subscribers_count":2,"default_branch":"develop","last_synced_at":"2025-07-06T18:06:29.949Z","etag":null,"topics":["api","fastapi"],"latest_commit_sha":null,"homepage":"","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/qcri.png","metadata":{"files":{"readme":"README.rst","changelog":null,"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":"AUTHORS.rst","dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-05-24T09:44:18.000Z","updated_at":"2023-05-02T12:51:06.000Z","dependencies_parsed_at":"2024-05-21T17:55:57.558Z","dependency_job_id":"3c6334f5-bef4-42eb-9888-fd5d5d31f6cf","html_url":"https://github.com/qcri/apihub","commit_stats":null,"previous_names":["yifan/apihub"],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/qcri/apihub","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qcri%2Fapihub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qcri%2Fapihub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qcri%2Fapihub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qcri%2Fapihub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/qcri","download_url":"https://codeload.github.com/qcri/apihub/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qcri%2Fapihub/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274681434,"owners_count":25330236,"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","status":"online","status_checked_at":"2025-09-11T02:00:13.660Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["api","fastapi"],"created_at":"2024-09-24T19:55:56.786Z","updated_at":"2026-02-15T10:07:10.995Z","avatar_url":"https://github.com/qcri.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":".. raw:: html\n\n   \u003c!-- PROJECT SHIELDS --\u003e\n\n.. raw:: html\n\n   \u003c!--\n   *** I'm using markdown \"reference style\" links for readability.\n   *** Reference links are enclosed in brackets [ ] instead of parentheses ( ).\n   *** See the bottom of this document for the declaration of the reference variables\n   *** for contributors-url, forks-url, etc. This is an optional, concise syntax you may use.\n   *** https://www.markdownguide.org/basic-syntax/#reference-style-links\n   --\u003e\n\n|Contributors| |Forks| |Stargazers| |Issues| |MIT License| |LinkedIn|\n\n.. raw:: html\n\n   \u003c!-- PROJECT LOGO --\u003e\n   \u003cbr /\u003e\n    \u003cp align=\"center\"\u003e\n      \u003ca href=\"https://github.com/yifan/apihub\"\u003e\n        \u003cimg src=\"https://raw.githubusercontent.com/yifan/apihub/master/images/APIHub-logo.png\" alt=\"Logo\" width=\"200\" height=\"100\"\u003e\n      \u003c/a\u003e\n\n      \u003ch3 align=\"center\"\u003eAPIHub\u003c/h3\u003e\n\n      \u003cp align=\"center\"\u003e\n        APIHub is a platform to dynamically serve API services on-fly. API service workers can be deployed when needed.\n        \u003cbr /\u003e\n        \u003ca href=\"https://github.com/yifan/apihub\"\u003e\u003cstrong\u003eExplore the docs »\u003c/strong\u003e\u003c/a\u003e\n        \u003cbr /\u003e\n        \u003cbr /\u003e\n        \u003ca href=\"https://github.com/yifan/apihub\"\u003eView Demo\u003c/a\u003e\n        ·\n        \u003ca href=\"https://github.com/yifan/apihub/issues\"\u003eReport Bug\u003c/a\u003e\n        ·\n        \u003ca href=\"https://github.com/yifan/apihub/issues\"\u003eRequest Feature\u003c/a\u003e\n      \u003c/p\u003e\n        \u003cbr /\u003e\n        \u003ca href=\"https://github.com/yifan/apihub\"\u003e\u003cstrong\u003eExplore the docs »\u003c/strong\u003e\u003c/a\u003e\n        \u003cbr /\u003e\n        \u003cbr /\u003e\n        \u003ca href=\"https://github.com/yifan/apihub\"\u003eView Demo\u003c/a\u003e\n        ·\n        \u003ca href=\"https://github.com/yifan/apihub/issues\"\u003eReport Bug\u003c/a\u003e\n        ·\n        \u003ca href=\"https://github.com/yifan/apihub/issues\"\u003eRequest Feature\u003c/a\u003e\n      \u003c/p\u003e\n    \u003c/p\u003e\n\n.. raw:: html\n\n   \u003c!-- TABLE OF CONTENTS --\u003e\n    \u003cdetails open=\"open\"\u003e\n      \u003csummary\u003e\u003ch2 style=\"display: inline-block\"\u003eTable of Contents\u003c/h2\u003e\u003c/summary\u003e\n      \u003col\u003e\n        \u003cli\u003e\n          \u003ca href=\"#about-the-project\"\u003eAbout The Project\u003c/a\u003e\n          \u003cul\u003e\n            \u003cli\u003e\u003ca href=\"#built-with\"\u003eBuilt With\u003c/a\u003e\u003c/li\u003e\n          \u003c/ul\u003e\n        \u003c/li\u003e\n        \u003cli\u003e\n          \u003ca href=\"#getting-started\"\u003eGetting Started\u003c/a\u003e\n          \u003cul\u003e\n            \u003cli\u003e\u003ca href=\"#prerequisites\"\u003ePrerequisites\u003c/a\u003e\u003c/li\u003e\n            \u003cli\u003e\u003ca href=\"#installation\"\u003eInstallation\u003c/a\u003e\u003c/li\u003e\n          \u003c/ul\u003e\n        \u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#usage\"\u003eUsage\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#roadmap\"\u003eRoadmap\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#contributing\"\u003eContributing\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#license\"\u003eLicense\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#contact\"\u003eContact\u003c/a\u003e\u003c/li\u003e\n        \u003cli\u003e\u003ca href=\"#acknowledgements\"\u003eAcknowledgements\u003c/a\u003e\u003c/li\u003e\n      \u003c/ol\u003e\n    \u003c/details\u003e\n\n\n\n.. |workflows| images:: https://github.com/yifan/apihub/actions/workflows/pytest-redis-postgres-workflow.yml/badge.svg\n\n\n\nAbout The Project\n=================\n\n`[Product Name Screen\nShot][product-screenshot] \u003chttps://raw.githubusercontent.com/yifan/apihub/master/images/APIHub.png\u003e`__\n\n\n\nFeatures \u0026 TODOs\n----------------\n\n\n|check| Security\n\n    |check| authenticate\n\n    |check| admin, manager, user\n\n    |check| user management\n\n    |check| rate limiter\n\n    |check| register\n\n    |uncheck_| social login\n\n|check| Subscription\n\n    |check| subscription\n\n    |check| application token\n\n    |check| daily usage record in redis\n\n|uncheck| Async/sync API calls\n\n    |check| api worker reports input/output: describe\n\n    |check| generic worker deployment \n\n    |uncheck| auto scaler for api workers\n\n\nBuilt With\n----------\n\n-  `fastapi \u003chttps://fastapi.tiangolo.com/\u003e`__\n-  `SQLAlchemy \u003chttps://www.sqlalchemy.org/\u003e`__\n-  `pydantic \u003chttps://pydantic-docs.helpmanual.io/\u003e`__\n-  `tanbih-pipeline \u003chttps://github.com/yifan/pipeline\u003e`__\n-  `psycopg2 \u003chttps://pypi.org/project/psycopg2/\u003e`__\n-  `redis \u003chttps://pypi.org/project/redis/\u003e`__\n-  `poetry \u003chttps://python-poetry.org/\u003e`__\n\n.. raw:: html\n\n   \u003c!-- GETTING STARTED --\u003e\n\nGetting Started\n===============\n\nTo get a local copy up and running follow these simple steps.\n\nPrerequisites\n-------------\n\nThis is an example of how to list things you need to use the software\nand how to install them.\n\nInstallation\n------------\n\n1. Clone the repo\n\n   .. code:: sh\n\n      git clone https://github.com/yifan/apihub.git\n\n2. Install python packages\n\n   .. code:: sh\n\n      poetry install\n\n.. raw:: html\n\n   \u003c!-- USAGE EXAMPLES --\u003e\n\nUsage\n=====\n\nUse this space to show useful examples of how a project can be used.\nAdditional screenshots, code examples and demos work well in this space.\nYou may also link to more resources.\n\n*For more examples, please refer to\nthe*\\ `Documentation \u003chttps://example.com\u003e`__\n\n.. raw:: html\n\n   \u003c!-- ROADMAP --\u003e\n\nRoadmap\n=======\n\nSee the `open issues \u003chttps://github.com/yifan/apihub/issues\u003e`__ for a\nlist of proposed features (and known issues).\n\n.. raw:: html\n\n   \u003c!-- CONTRIBUTING --\u003e\n\nContributing\n============\n\nContributions are what make the open source community such an amazing\nplace to be learn, inspire, and create. Any contributions you make are\n**greatly appreciated**.\n\n1. Fork the Project\n2. Create your Feature Branch\n   (``git checkout -b feature/AmazingFeature``)\n3. Commit your Changes (``git commit -m 'Add some AmazingFeature'``)\n4. Push to the Branch (``git push origin feature/AmazingFeature``)\n5. Open a Pull Request\n\nTesting\n=======\n\n1. Start postgres and redis\n\n   .. code:: sh\n\n      docker compose up\n\n2. Setup environment variables in a local .env file\n\n   .. code:: sh\n\n      cat \u003e.env \u003c\u003cEOF\n      DB_URI=\"postgresql://dbuser:dbpass@localhost:5432/test\"\n      JWT_SECRET=\"nosecret\"\n      REDIS=\"redis://localhost:6379/1\"\n      IN_REDIS=\"redis://localhost:6379/1\"\n      OUT_REDIS=\"redis://localhost:6379/1\"\n      SECURITY_TOKEN_EXPIRES_DAYS=1\n      SUBSCRIPTION_TOKEN_EXPIRES_DAYS=1\n      EOF\n\n3. Run tests\n\n   .. code:: sh\n\n      poetry run test\n\n4. Shutdown docker services\n\n   .. code:: sh\n\n      docker compose down\n\n.. raw:: html\n\n   \u003c!-- LICENSE --\u003e\n\nLicense\n=======\n\nDistributed under the MIT License. See ``LICENSE`` for more information.\n\n.. raw:: html\n\n   \u003c!-- CONTACT --\u003e\n\nContact\n=======\n\nYifan Zhang - [@yifan2019](https://twitter.com/yifan2019) -\nyzhang@hbku.edu.qa\n\nProject Link: https://github.com/yifan/apihub\n\n.. raw:: html\n\n   \u003c!-- ACKNOWLEDGEMENTS --\u003e\n\nAcknowledgements\n================\n\n-  \n-  \n-  \n\nCopyright (C) 2021, Qatar Computing Research Institute, HBKU\n\n.. raw:: html\n\n   \u003c!-- MARKDOWN LINKS \u0026 IMAGES --\u003e\n\n.. raw:: html\n\n   \u003c!-- https://www.markdownguide.org/basic-syntax/#reference-style-links --\u003e\n\n.. |check| raw:: html\n   \n   \u003cinput checked=\"\"  type=\"checkbox\"\u003e\n\n.. |check_| raw:: html\n\n   \u003cinput checked=\"\"  disabled=\"\" type=\"checkbox\"\u003e\n\n.. |uncheck| raw:: html\n\n   \u003cinput type=\"checkbox\"\u003e\n\n.. |uncheck_| raw:: html\n\n   \u003cinput disabled=\"\" type=\"checkbox\"\u003e\n\n\n.. |Contributors| image:: https://img.shields.io/github/contributors/yifan/apihub.svg?style=for-the-badge\n   :target: https://github.com/yifan/apihub/graphs/contributors\n.. |Forks| image:: https://img.shields.io/github/forks/yifan/apihub.svg?style=for-the-badge\n   :target: https://github.com/yifan/apihub/network/members\n.. |Stargazers| image:: https://img.shields.io/github/stars/yifan/apihub.svg?style=for-the-badge\n   :target: https://github.com/yifan/apihub/stargazers\n.. |Issues| image:: https://img.shields.io/github/issues/yifan/apihub.svg?style=for-the-badge\n   :target: https://github.com/yifan/apihub/issues\n.. |MIT License| image:: https://img.shields.io/github/license/yifan/apihub.svg?style=for-the-badge\n   :target: https://github.com/yifan/apihub/blob/master/LICENSE\n.. |LinkedIn| image:: https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge\u0026logo=linkedin\u0026colorB=555\n   :target: https://linkedin.com/in/yifanzhang\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqcri%2Fapihub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqcri%2Fapihub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqcri%2Fapihub/lists"}