292 stable releases

Uses new Rust 2021

new 3.0.12 Dec 5, 2021
3.0.10 Nov 30, 2021
2.11.3 Nov 13, 2021
2.9.9 Jul 20, 2021
0.10.8 Mar 10, 2020

#9 in Asynchronous

Download history 6426/week @ 2021-08-15 7913/week @ 2021-08-22 5567/week @ 2021-08-29 6479/week @ 2021-09-05 7972/week @ 2021-09-12 8680/week @ 2021-09-19 8359/week @ 2021-09-26 8664/week @ 2021-10-03 7052/week @ 2021-10-10 7739/week @ 2021-10-17 7948/week @ 2021-10-24 6108/week @ 2021-10-31 5690/week @ 2021-11-07 7958/week @ 2021-11-14 6639/week @ 2021-11-21 8596/week @ 2021-11-28

29,351 downloads per month
Used in 35 crates (33 directly)

MIT/Apache

1MB
27K SLoC

A GraphQL server library implemented in Rust

Async-graphql is a high-performance server-side library that supports all GraphQL specifications.

Safety

This crate uses #![forbid(unsafe_code)] to ensure everything is implemented in 100% Safe Rust.

Features

  • Fully supports async/await
  • Type safety
  • Rustfmt friendly (Procedural Macro)
  • Custom scalars
  • Minimal overhead
  • Easy integration (poem, actix_web, tide, warp, rocket ...)
  • Upload files (Multipart request)
  • Subscriptions (WebSocket transport)
  • Custom extensions
  • Apollo Tracing extension
  • Limit query complexity/depth
  • Error Extensions
  • Apollo Federation
  • Batch Queries
  • Apollo Persisted Queries

Crate features

This crate offers the following features, all of which are not activated by default:

Apollo Studio

Apollo Studio is a cloud platform that helps you build, monitor, validate, and secure your organization's data graph. An existing extension is available for this crate here

Examples

All examples are in the sub-repository, located in the examples directory.

Run an example:

git submodule update # update the examples repo
cd examples && cargo run --bin [name]

Integrations

Who's using Async-graphql in production?

Community Showcase

  • rust-actix-graphql-sqlx-postgresql Using GraphQL with Rust and Apollo Federation
  • entity-rs A simplistic framework based on TAO, Facebook's distributed database for Social Graph.
  • vimwiki-server Provides graphql server to inspect and manipulate vimwiki files.
  • Diana Diana is a GraphQL system for Rust that's designed to work as simply as possible out of the box, without sacrificing configuration ability.
  • cindythink

Blog Posts

License

Licensed under either of

References

Contribute

Welcome to contribute !

Dependencies

~9–13MB
~329K SLoC