{"id":37074098,"url":"https://github.com/luolingchun/star-openapi","last_synced_at":"2026-01-14T08:43:38.395Z","repository":{"id":332041071,"uuid":"1127600786","full_name":"luolingchun/star-openapi","owner":"luolingchun","description":"A simple async API framework based on Starlette.","archived":false,"fork":false,"pushed_at":"2026-01-12T06:21:10.000Z","size":1546,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-12T15:37:49.337Z","etag":null,"topics":["openapi","openapi3","pydantic","python3","redoc","scalar","starlette","swagger"],"latest_commit_sha":null,"homepage":"https://luolingchun.github.io/star-openapi/","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/luolingchun.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","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,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-04T08:08:58.000Z","updated_at":"2026-01-12T06:20:32.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/luolingchun/star-openapi","commit_stats":null,"previous_names":["luolingchun/star-openapi"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/luolingchun/star-openapi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luolingchun%2Fstar-openapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luolingchun%2Fstar-openapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luolingchun%2Fstar-openapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luolingchun%2Fstar-openapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/luolingchun","download_url":"https://codeload.github.com/luolingchun/star-openapi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luolingchun%2Fstar-openapi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28414692,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T08:38:59.149Z","status":"ssl_error","status_checked_at":"2026-01-14T08:38:43.588Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["openapi","openapi3","pydantic","python3","redoc","scalar","starlette","swagger"],"created_at":"2026-01-14T08:43:37.808Z","updated_at":"2026-01-14T08:43:38.373Z","avatar_url":"https://github.com/luolingchun.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n    \u003ca href=\"https://luolingchun.github.io/star-openapi/\" target=\"_blank\"\u003e\n        \u003cimg class=\"off-glb\" src=\"https://raw.githubusercontent.com/luolingchun/star-openapi/main/docs/images/logo-text.svg\" \n             width=\"60%\" height=\"auto\" alt=\"logo\"\u003e\n    \u003c/a\u003e\n\u003c/div\u003e\n\u003cp align=\"center\"\u003e\n    \u003cem\u003eA simple async API framework based on Starlette.\u003c/em\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/luolingchun/star-openapi/actions/workflows/tests.yml\" target=\"_blank\"\u003e\n        \u003cimg class=\"off-glb\" src=\"https://img.shields.io/github/actions/workflow/status/luolingchun/star-openapi/tests.yml?branch=main\" alt=\"test\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://pypi.org/project/star-openapi/\" target=\"_blank\"\u003e\n        \u003cimg class=\"off-glb\" src=\"https://img.shields.io/pypi/v/star-openapi\" alt=\"pypi\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://pypistats.org/packages/star-openapi\" target=\"_blank\"\u003e\n        \u003cimg class=\"off-glb\" src=\"https://img.shields.io/pypi/dm/star-openapi\" alt=\"pypistats\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://pypi.org/project/star-openapi/\" target=\"_blank\"\u003e\n        \u003cimg class=\"off-glb\" src=\"https://img.shields.io/pypi/pyversions/star-openapi\" alt=\"pypi versions\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n**Star OpenAPI** is a web API framework based on **Starlette**. It uses **Pydantic** to verify data and automatic\ngeneration of interaction documentation.\n\nThe key features are:\n\n- **Easy to code:** Easy to use and easy to learn\n\n- **Standard document specification:** Based on [OpenAPI Specification](https://spec.openapis.org/oas/v3.1.0)\n\n- **Interactive OpenAPI documentation:**\n  [Swagger](https://github.com/swagger-api/swagger-ui), [Redoc](https://github.com/Redocly/redoc), [RapiDoc](https://github.com/rapi-doc/RapiDoc), [RapiPdf](https://mrin9.github.io/RapiPdf/), [Scalar](https://github.com/scalar/scalar), [Elements](https://github.com/stoplightio/elements)\n\n- **Data validation:** Fast data verification based on [Pydantic](https://github.com/pydantic/pydantic)\n\n- **Websocket**: Support for websocket\n\n## Requirements\n\nPython 3.11+\n\nstar-openapi is dependent on the following libraries:\n\n- [Starlette](https://github.com/Kludex/starlette) for the web app.\n- [Pydantic](https://github.com/pydantic/pydantic) for the data validation.\n\n## Installation\n\n```bash\npip install -U star-openapi[swagger]\n```\n\n\u003cdetails markdown=\"block\"\u003e\n\u003csummary\u003eOptional dependencies\u003c/summary\u003e\n\n- [`httpx`](https://github.com/encode/httpx/) - Required if you want to use the `TestClient`.\n- [`python-multipart`](https://github.com//kludex/python-multipart) - Required if you want to support form parsing, with\n  `request.form()`.\n- [`itsdangerous`](https://github.com/pallets/itsdangerous) - Required for `SessionMiddleware` support.\n- [`pyyaml`](https://github.com/yaml/pyyaml) - Required for `SchemaGenerator` support.\n\nYou can install all of these with `pip install star-openapi[full]`.\n\n- [star-openapi-plugins](https://github.com/luolingchun/star-openapi-plugins) Provide OpenAPI UI for star-openapi.\n\nYou can install all of these with `pip install star-openapi[swagger,redoc,rapidoc,rapipdf,scalar,elements]`.\n\n\u003c/details\u003e\n\n## A Simple Example\n\nHere's a simple example, further go to the [Example](https://luolingchun.github.io/star-openapi/v0.x/Example/).\n\n```python\nimport uvicorn\nfrom pydantic import BaseModel\nfrom starlette.responses import JSONResponse\n\nfrom star_openapi import OpenAPI\n\ninfo = {\"title\": \"Star API\", \"version\": \"1.0.0\"}\napp = OpenAPI(info=info)\n\nbook_tag = {\"name\": \"book\", \"description\": \"book tag\"}\n\n\nclass BookModel(BaseModel):\n    name: str\n    age: int\n\n\n@app.post(\"/book\", summary=\"get books\", tags=[book_tag])\nasync def create_user(body: BookModel):\n    \"\"\"\n    get all books\n    \"\"\"\n    print(body.model_dump_json())\n    return JSONResponse({\"message\": \"Hello World\"})\n\n\nif __name__ == \"__main__\":\n    print(app.routes)\n    uvicorn.run(app)\n```\n\n## API Document\n\nRun the [simple example](https://github.com/luolingchun/star-openapi/blob/main/examples/simple_demo.py), and go\nto http://127.0.0.1:8000/openapi.\n\n\u003e OpenAPI UI plugins are optional dependencies that require manual installation.\n\u003e\n\u003e `pip install -U star-openapi[swagger,redoc,rapidoc,rapipdf,scalar,elements]`\n\u003e\n\u003e More optional ui templates goto the document\n\u003e about [UI_Templates](https://luolingchun.github.io/star-openapi/v0.x/Usage/UI_Templates/).\n\n![openapi](https://raw.githubusercontent.com/luolingchun/star-openapi/main/docs/assets/openapi-all.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluolingchun%2Fstar-openapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fluolingchun%2Fstar-openapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluolingchun%2Fstar-openapi/lists"}