{"repo":"strawberry-graphql/strawberry","free":true,"listed":false,"github":"https://github.com/strawberry-graphql/strawberry","clone":"git clone https://github.com/strawberry-graphql/strawberry.git","description":"A GraphQL library for Python that leverages type annotations 🍓","language":"Python","stars":4704,"topics":["graphql","graphql-server","python","starlette","asyncio","mypy","django","graphql-library","asgi","graphql-schema"],"license":"MIT","category":"api-integrations-sdks","readme_excerpt":"Strawberry GraphQL Python GraphQL library based on dataclasses Installation ( Quick Start ) The quick start method provides a server and CLI to get going quickly. Install with: Getting Started Create a file called app.py with the following code: This will create a GraphQL schema defining a User type and a single query field user that will return a hardcoded user. To serve the schema using the dev server run the following command: Open the dev server by clicking on the following link: http://0.0.0.0:8000/graphql This will open GraphiQL where you can test the API. Type-checking Strawberry comes with a [mypy] plugin that enables statically type-checking your GraphQL schema. To enable it, add the following lines to your mypy.ini configuration: [mypy]: http://www.mypy-lang.org/ Django Integration A Django view is provided for adding a GraphQL endpoint to your application. 1. Add the app to your INSTALLED APPS . 2. Add the view to your urls.py file. Examples Various examples on how to use Strawberry Full stack example using Starlette, SQLAlchemy, Typescript codegen and Next.js Quart + Strawberry tutorial Contributing We use uv to manage dependencies, to get started follow these steps: For all further detail, check out the Contributing Page Pre commit We have a configuration for pre-commit, to add the hook run the following command: Links - Project homepage: https://strawberry.rocks - Repository: https://github.com/strawberry-graphql/strawberry - Issue tracker: https://github.com/st","default_branch":null,"files":null,"tree":[],"storefront":"/r/strawberry-graphql","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/strawberry-graphql/strawberry/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}