74 stable releases

Uses new Rust 2021

new 4.0.4 Jun 25, 2022
4.0.1 May 24, 2022
3.0.38 Apr 9, 2022
3.0.37 Mar 30, 2022
2.0.5 Oct 19, 2020

#732 in Asynchronous

Download history 15463/week @ 2022-03-10 14960/week @ 2022-03-17 13787/week @ 2022-03-24 15069/week @ 2022-03-31 15445/week @ 2022-04-07 11673/week @ 2022-04-14 14258/week @ 2022-04-21 15711/week @ 2022-04-28 15685/week @ 2022-05-05 16558/week @ 2022-05-12 14811/week @ 2022-05-19 14084/week @ 2022-05-26 18410/week @ 2022-06-02 19274/week @ 2022-06-09 18232/week @ 2022-06-16 18512/week @ 2022-06-23

77,574 downloads per month
Used in 57 crates (8 directly)

MIT/Apache

67KB
2K 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
  • sudograph

Blog Posts

License

Licensed under either of

References

Contribute

Welcome to contribute !

Dependencies

~1.2–2MB
~43K SLoC