{"id":16691317,"url":"https://github.com/gr1n/aioapi","last_synced_at":"2025-03-23T14:31:39.661Z","repository":{"id":57408741,"uuid":"157118643","full_name":"Gr1N/aioapi","owner":"Gr1N","description":"Yet another way to build APIs using AIOHTTP framework","archived":false,"fork":false,"pushed_at":"2020-02-14T14:06:57.000Z","size":865,"stargazers_count":13,"open_issues_count":5,"forks_count":2,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-18T21:16:50.206Z","etag":null,"topics":["aiohttp","aiohttp-server","annotations","api","apis","typing"],"latest_commit_sha":null,"homepage":"https://gr1n.github.io/aioapi/","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/Gr1N.png","metadata":{"files":{"readme":"README.md","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}},"created_at":"2018-11-11T20:34:31.000Z","updated_at":"2023-08-02T00:50:32.000Z","dependencies_parsed_at":"2022-09-26T17:11:04.557Z","dependency_job_id":null,"html_url":"https://github.com/Gr1N/aioapi","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gr1N%2Faioapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gr1N%2Faioapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gr1N%2Faioapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gr1N%2Faioapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Gr1N","download_url":"https://codeload.github.com/Gr1N/aioapi/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245115959,"owners_count":20563262,"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":["aiohttp","aiohttp-server","annotations","api","apis","typing"],"created_at":"2024-10-12T16:07:51.187Z","updated_at":"2025-03-23T14:31:39.218Z","avatar_url":"https://github.com/Gr1N.png","language":"Python","readme":"# aioapi\n\n[![Build Status](https://github.com/Gr1N/aioapi/workflows/default/badge.svg)](https://github.com/Gr1N/aioapi/actions?query=workflow%3Adefault) [![codecov](https://codecov.io/gh/Gr1N/aioapi/branch/master/graph/badge.svg)](https://codecov.io/gh/Gr1N/aioapi) ![PyPI](https://img.shields.io/pypi/v/aioapi.svg?label=pypi%20version) ![PyPI - Downloads](https://img.shields.io/pypi/dm/aioapi.svg?label=pypi%20downloads) ![GitHub](https://img.shields.io/github/license/Gr1N/aioapi.svg)\n\nYet another way to build APIs using [`AIOHTTP`](https://aiohttp.readthedocs.io/) framework.\n\nFollow [documentation](https://gr1n.github.io/aioapi/) to know what you can do with `AIOAPI`.\n\n## Installation\n\n```sh\n$ pip install aioapi\n```\n\n## Usage \u0026 Examples\n\nBelow you can find a simple, but powerful example of `AIOAPI` library usage:\n\n```python\nimport aioapi as api\nfrom aioapi import Body, PathParam\nfrom aioapi.middlewares import validation_error_middleware\nfrom aiohttp import web\nfrom pydantic import BaseModel\n\n\nclass User(BaseModel):\n    name: str\n    age: int = 42\n\n\nasync def hello_body(user_id: PathParam[int], body: Body[User]):\n    user = body.cleaned\n    return web.json_response(\n        {\"id\": user_id.cleaned, \"name\": user.name, \"age\": user.age}\n    )\n\n\ndef main():\n    app = web.Application()\n\n    app.add_routes([api.post(\"/hello/{user_id}\", hello_body)])\n    app.middlewares.append(validation_error_middleware)\n\n    web.run_app(app)\n\n\nif __name__ == \"__main__\":\n    main()\n```\n\nAnd there are also more examples of usage at [`examples/`](https://github.com/Gr1N/aioapi/tree/master/example) directory.\n\nTo run them use command below:\n\n```sh\n$ make example\n```\n\n## Contributing\n\nTo work on the `AIOAPI` codebase, you'll want to clone the project locally and install the required dependencies via [poetry](https://poetry.eustace.io):\n\n```sh\n$ git clone git@github.com:Gr1N/aioapi.git\n$ make install\n```\n\nTo run tests and linters use command below:\n\n```sh\n$ make lint \u0026\u0026 make test\n```\n\nIf you want to run only tests or linters you can explicitly specify what you want to run, e.g.:\n\n```sh\n$ make lint-black\n```\n\n## Milestones\n\nIf you're interesting in project's future you can find milestones and plans at [projects](https://github.com/Gr1N/aioapi/projects) page.\n\n## License\n\n`AIOAPI` is licensed under the MIT license. See the license file for details.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgr1n%2Faioapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgr1n%2Faioapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgr1n%2Faioapi/lists"}