{"id":13549888,"url":"https://github.com/gql-dart/gql","last_synced_at":"2025-08-17T23:05:25.381Z","repository":{"id":35053514,"uuid":"201116626","full_name":"gql-dart/gql","owner":"gql-dart","description":"Libraries supporting GraphQL in Dart","archived":false,"fork":false,"pushed_at":"2025-05-18T02:57:18.000Z","size":3222,"stargazers_count":268,"open_issues_count":81,"forks_count":125,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-07-15T18:20:42.127Z","etag":null,"topics":["dart","flutter","graphql"],"latest_commit_sha":null,"homepage":"","language":"Dart","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/gql-dart.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-08-07T19:40:20.000Z","updated_at":"2025-07-10T03:04:00.000Z","dependencies_parsed_at":"2023-11-11T21:23:28.973Z","dependency_job_id":"edcdbe3c-e63e-4917-b4a0-784a88962700","html_url":"https://github.com/gql-dart/gql","commit_stats":null,"previous_names":[],"tags_count":31,"template":false,"template_full_name":null,"purl":"pkg:github/gql-dart/gql","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gql-dart%2Fgql","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gql-dart%2Fgql/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gql-dart%2Fgql/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gql-dart%2Fgql/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gql-dart","download_url":"https://codeload.github.com/gql-dart/gql/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gql-dart%2Fgql/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270800140,"owners_count":24648133,"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-08-17T02:00:09.016Z","response_time":129,"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":["dart","flutter","graphql"],"created_at":"2024-08-01T12:01:26.685Z","updated_at":"2025-08-17T23:05:25.341Z","avatar_url":"https://github.com/gql-dart.png","language":"Dart","funding_links":[],"categories":["Dart"],"sub_categories":[],"readme":"## `gql-dart/gql` \n\n[![MIT License][license-badge]][license-link]\n[![PRs Welcome][prs-badge]][prs-link]\n[![Watch on GitHub][github-watch-badge]][github-watch-link]\n[![Star on GitHub][github-star-badge]][github-star-link]\n[![Watch on GitHub][github-forks-badge]][github-forks-link]\n[![Discord][discord-badge]][discord-link]\n\n[license-badge]: https://img.shields.io/github/license/gql-dart/gql.svg?style=for-the-badge\n[license-link]: https://github.com/gql-dart/gql/blob/master/LICENSE\n[prs-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=for-the-badge\n[prs-link]: https://github.com/gql-dart/gql/issues\n\n[github-watch-badge]: https://img.shields.io/github/watchers/gql-dart/gql.svg?style=for-the-badge\u0026logo=github\u0026logoColor=ffffff\n[github-watch-link]: https://github.com/gql-dart/gql/watchers\n[github-star-badge]: https://img.shields.io/github/stars/gql-dart/gql.svg?style=for-the-badge\u0026logo=github\u0026logoColor=ffffff\n[github-star-link]: https://github.com/gql-dart/gql/stargazers\n[github-forks-badge]: https://img.shields.io/github/forks/gql-dart/gql.svg?style=for-the-badge\u0026logo=github\u0026logoColor=ffffff\n[github-forks-link]: https://github.com/gql-dart/gql/network/members\n\n[discord-badge]: https://img.shields.io/discord/559455668810153989.svg?style=for-the-badge\u0026logo=discord\u0026logoColor=ffffff\n[discord-link]: https://discord.gg/YBFCTXNbwY\n\n\nThis is an effort to advance the Dart GraphQL ecosystem.\n\nIt consists of multiple packages and libraries centered around GraphQL AST.\n\n![Packages](docs/gql.svg)\n\n#### Core\n\nThe core of this project is the GraphQL parser which parses GraphQL strings into an AST. The parsed AST can then be transformed, visited and printed back to GraphQL string.\n\n| Pub | Package | Library | Description |\n|-----|---------|---------|-------------|\n| [![version][package:gql:version]][package:gql] | [`package:gql`][package:gql:source] | `ast.dart` | GraphQL AST implementation with Visitor pattern and AST transformer |\n| [![version][package:gql:version]][package:gql] | [`package:gql`][package:gql:source] | `language.dart` | GraphQL source parser and printer. Recognizes both operations and SDL |\n| [![version][package:gql:version]][package:gql] | [`package:gql`][package:gql:source] | `document.dart` | Document and schema validation |\n\n#### Code generation\n\nGraphQL language enables code generation to speed up development and move document processing to build-time.\n  \nWe provide code builders to generate Dart source code and file builders which easily plug into standard Dart code generation pipeline.\n\nIdeas for future work:\n- Typed resolvers for field resolution on the client or server\n\n| Pub | Package | Library | Description |\n|-----|---------|---------|-------------|\n| [![version][package:gql_code_builder:version]][package:gql_code_builder] | [`package:gql_code_builder`][package:gql_code_builder:source] |  | Various builders |\n| [![version][package:gql_build:version]][package:gql_build] | [`package:gql_build`][package:gql_build:source] |  | File builders |\n\n#### Client\n\nTo enable development of GraphQL clients, we provide type definitions used to execute GraphQL operations. They include AST-based operation, request with per operation context, and response. These types are used by the Links.\n\nLink is the current client implementation. Link is GraphQL AST-aware request/response middleware. They can be used to build a pipeline to deduplicate requests, conditionally transform requests and responses (including the context), and eventually send the requests to the server.\n\nIdeas for future work:\n- websocket link for subscriptions\n- batched request HTTP link\n- retry link to handle network issues transparently\n- link for client-side request resolution \n\n| Pub | Package | Library | Description |\n|-----|---------|---------|-------------|\n| [![version][package:gql_exec:version]][package:gql_exec] | [`package:gql_exec`][package:gql_exec:source] | `gql_exec.dart` | Implementation of types for GraphQL requests and responses |\n| [![version][package:gql_link:version]][package:gql_link] | [`package:gql_link`][package:gql_link:source] | `link.dart` | Base for modular GraphQL execution interface |\n| [![version][package:gql_http_link:version]][package:gql_http_link] | [`package:gql_http_link`][package:gql_http_link:source] | `gql_http_link.dart` | Link to execute GraphQL requests via HTTP |\n| [![version][package:gql_dedupe_link:version]][package:gql_dedupe_link] | [`package:gql_dedupe_link`][package:gql_dedupe_link:source] | `gql_dedupe_link.dart` | De-duplicating Link to avoid execution of identical requests |\n| [![version][package:gql_transform_link:version]][package:gql_transform_link] | [`package:gql_transform_link`][package:gql_transform_link:source] | `gql_transform_link.dart` | GQL Link to transform Requests and Responses. May be used to update context, document, variables, data, errors, etc. |\n| [![version][package:gql_websocket_link:version]][package:gql_websocket_link] | [`package:gql_websocket_link`][package:gql_websocket_link:source] | `gql_websocket_link.dart` | GQL Link for subscriptions using websocket. |\n| [![version][package:gql_dio_link:version]][package:gql_dio_link] | [`package:gql_dio_link`][package:gql_dio_link:source] | `gql_dio_link.dart` | Similar to gql_http_link, A GQL Terminating Link to execute requests via Dio using JSON. |\n\n#### Other\n\n| Pub | Package | Library | Description |\n|-----|---------|---------|-------------|\n| [![version][package:gql_pedantic:version]][package:gql_pedantic] | [`package:gql_pedantic`][package:gql_pedantic:source] |  | Lint rules used by all `gql-dart/gql` packages |\n\n#### Examples\n\n| Pub | Package | Library | Description |\n|-----|---------|---------|-------------|\n| [![version][package:gql_example_cli:version]][package:gql_example_cli] | [`package:gql_example_cli`][package:gql_example_cli:source] |  | Example usage in a CLI environment |\n| [![version][package:gql_example_flutter:version]][package:gql_example_flutter] | [`package:gql_example_flutter`][package:gql_example_flutter:source] |  | Example usage in a Flutter environment |\n\n\n[package:gql:source]: ./gql/README.md\n[package:gql]: https://pub.dartlang.org/packages/gql\n[package:gql:version]: https://img.shields.io/pub/v/gql.svg?style=flat-square \n[package:gql_exec:source]: ./links/gql_exec/README.md\n[package:gql_exec]: https://pub.dartlang.org/packages/gql_exec\n[package:gql_exec:version]: https://img.shields.io/pub/v/gql_exec.svg?style=flat-square\n[package:gql_websocket_link]: https://pub.dartlang.org/packages/gql_websocket_link\n[package:gql_websocket_link:source]: ./links/gql_websocket_link/README.md\n[package:gql_websocket_link:version]: https://img.shields.io/pub/v/gql_websocket_link.svg?style=flat-square\n[package:gql_dio_link]: https://pub.dartlang.org/packages/gql_dio_link\n[package:gql_dio_link:source]: ./links/gql_dio_link/README.md\n[package:gql_dio_link:version]: https://img.shields.io/pub/v/gql_dio_link.svg?style=flat-square\n[package:gql_link:source]: ./links/gql_link/README.md\n[package:gql_link]: https://pub.dartlang.org/packages/gql_link\n[package:gql_link:version]: https://img.shields.io/pub/v/gql_link.svg?style=flat-square \n[package:gql_http_link:source]: ./links/gql_http_link/README.md\n[package:gql_http_link]: https://pub.dartlang.org/packages/gql_http_link\n[package:gql_http_link:version]: https://img.shields.io/pub/v/gql_http_link.svg?style=flat-square \n[package:gql_code_builder:source]: ./codegen/gql_code_builder/README.md\n[package:gql_code_builder]: https://pub.dartlang.org/packages/gql_code_builder\n[package:gql_code_builder:version]: https://img.shields.io/pub/v/gql_code_builder.svg?style=flat-square \n[package:gql_build:source]: ./codegen/gql_build/README.md\n[package:gql_build]: https://pub.dartlang.org/packages/gql_build\n[package:gql_build:version]: https://img.shields.io/pub/v/gql_build.svg?style=flat-square \n[package:gql_dedupe_link:source]: ./links/gql_dedupe_link/README.md\n[package:gql_dedupe_link]: https://pub.dartlang.org/packages/gql_dedupe_link\n[package:gql_transform_link:version]: https://img.shields.io/pub/v/gql_transform_link.svg?style=flat-square \n[package:gql_transform_link:source]: ./links/gql_transform_link/README.md\n[package:gql_transform_link]: https://pub.dartlang.org/packages/gql_transform_link\n[package:gql_dedupe_link:version]: https://img.shields.io/pub/v/gql_dedupe_link.svg?style=flat-square \n[package:gql_pedantic:source]: ./gql_pedantic/README.md\n[package:gql_pedantic]: https://pub.dartlang.org/packages/gql_pedantic\n[package:gql_pedantic:version]: https://img.shields.io/pub/v/gql_pedantic.svg?style=flat-square\n[package:gql_example_cli:source]: ./examples/gql_example_cli/README.md\n[package:gql_example_cli]: https://pub.dartlang.org/packages/gql_example_cli\n[package:gql_example_cli:version]: https://img.shields.io/pub/v/gql_example_cli.svg?style=flat-square \n[package:gql_example_flutter:source]: ./examples/gql_example_flutter/README.md\n[package:gql_example_flutter]: https://pub.dartlang.org/packages/gql_example_flutter\n[package:gql_example_flutter:version]: https://img.shields.io/pub/v/gql_example_flutter.svg?style=flat-square \n\n\n## Users\n\n| Project | Description |\n|---------|-------------|\n| [artemis][artemis] | Build dart types from GraphQL schemas and queries (using Introspection Query). | \n| [graphql][graphql_flutter] | A stand-alone GraphQL client for Dart, bringing all the features from a modern GraphQL client to one easy to use package. |\n| [graphql_flutter][graphql_flutter] | A GraphQL client for Flutter, bringing all the features from a modern GraphQL client to one easy to use package. |\n| [normalize][normalize] | Normalization and denormalization of GraphQL responses in Dart |\n| [ferry][ferry] | GraphQL Client for Dart |\n| Your project? | Open a PR to add it to this readme! |\n\n[artemis]: https://github.com/comigor/artemis\n[graphql_flutter]: https://github.com/zino-app/graphql-flutter\n[normalize]: https://github.com/smkhalsa/normalize\n[ferry]: https://github.com/gql-dart/ferry\n\n## Contributing\n\nThe goal of this project is to expand Dart GraphQL ecosystem\nand to build a community around this vendor-neutral implementation.\n\nCommunity contributions are welcome.\n\n# Release Process\n\nThis repository uses [Melos](https://melos.invertase.dev) to manage the monorepo and handle releases. The release process is partially automated through GitHub Actions.\n\n## Repository Structure\n\nThe repository is organized into several package categories:\n\n- Core packages:\n  - `gql`: Core GraphQL package\n  - `gql_tristate_value`\n  - `gql_code_builder_serializers`\n  - `gql_code_builder`\n\n- Execution packages:\n  - `gql_exec`\n  - `gql_link`\n\n- Link implementations:\n  - `gql_http_link`\n  - `gql_dio_link`\n  - `gql_websocket_link`\n  - `gql_dedupe_link`\n  - `gql_error_link`\n  - `gql_transform_link`\n\n- Build packages:\n  - `gql_build`\n\n## Local Development\n\nTo get started with local development:\n\n1. Install Melos:\n   ```bash\n   dart pub global activate melos \u0026\u0026 dart pub get\n   ```\n\n2. Bootstrap the workspace:\n   ```bash\n   melos bootstrap\n   ```\n\n3. Run tests:\n   ```bash\n   melos test\n   ```\n\n## Release Process\n\n### Automated Publishing\n\nThe publish workflow is automated via GitHub Actions and triggers when:\n- Changes are pushed to the `master` or `release` branches AND include changes to any `pubspec.yaml` file\n- Manually triggered through GitHub Actions UI\n\nThe automated process:\n1. Validates all packages (formatting, analysis, and tests)\n2. Publishes packages in dependency order:\n   - Core packages first\n   - Execution packages second\n   - Link implementation packages third\n   - Build packages last\n\n### Manual Release Steps\n\nTo create a new release manually:\n\n1. Ensure you're on the branch you want to release from (`master` or `release`)\n\n2. Version the packages using one of the following commands:\n   ```bash\n   # For a patch release\n   melos run bump-patch\n\n   # For a minor release\n   melos run bump-minor\n\n   # For a major release\n   melos run bump-major\n\n   # For an alpha release\n   melos run bump-alpha\n\n   # To graduate from prerelease(alpha) to stable\n   melos run graduate\n   ```\n\n3. Push the changes and tags:\n   ```bash\n   git push \u0026\u0026 git push --tags\n   ```\n\n4. The GitHub Action will automatically handle publishing to pub.dev if changes include pubspec.yaml files\n\n### Versioning Rules\n\n- Use `bump-patch` for backward-compatible bug fixes\n- Use `bump-minor` for backward-compatible features\n- Use `bump-major` for breaking changes\n- Use `bump-alpha` for prerelease versions\n- Use `graduate` to promote prerelease versions to stable\n\n## Available Melos Commands\n\n- `melos bootstrap`: Set up the workspace\n- `melos clean`: Clean all packages\n- `melos test`: Run tests for all packages\n- `melos format`: Format all packages\n- `melos analyze`: Run static analysis\n- `melos build`: Run build_runner for all packages\n- `melos publish`: Publish packages to pub.dev\n\n## Troubleshooting\n\nIf the automated publish fails:\n\n1. Check the GitHub Actions logs for specific errors\n2. Ensure all tests are passing locally: `melos test`\n3. Verify that version numbers in `pubspec.yaml` files are correct\n4. Check that all dependencies are properly versioned\n\nFor manual publishing (if needed, requires pub dev authentication):\n```bash\nmelos publish --no-dry-run --yes --scope=\"package_name\"\n```\n\n## Notes\n\n- The publish workflow publishes packages in a specific order to handle dependencies correctly\n- All packages are versioned together to maintain consistency\n- The workflow automatically handles pub.dev credentials through GitHub Secrets\n- Changes to `pubspec.yaml` files automatically trigger the publish workflow\n\n## Features and bugs\n\nPlease file feature requests and bugs at the [GitHub][tracker].\n\n[tracker]: https://github.com/gql-dart/gql/issues\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgql-dart%2Fgql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgql-dart%2Fgql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgql-dart%2Fgql/lists"}