axum/examples
2025-12-27 20:38:51 +00:00
..
anyhow-error-response [test] the anyhow-error-response example (#3274) 2025-03-18 10:53:00 +01:00
async-graphql Remove lingering async-graphql example file 2023-01-08 16:28:45 +01:00
auto-reload Fix typo in auto-reload example. (#2680) 2024-03-26 10:22:59 +01:00
chat Reduce dependency on futures-util (#3358) 2025-05-25 09:39:35 +02:00
compression examples: Update to brotli 8 (#3473) 2025-09-13 10:29:21 +02:00
consume-body-in-extractor-or-middleware Replace async_trait with AFIT / RPITIT (#2308) 2024-09-28 21:27:11 +00:00
cors Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
customize-extractor-error axum-extra: Make axum optional dependency (#3485) 2025-10-29 16:58:10 +01:00
customize-path-rejection chore: Upgrade matchit to 0.8 (#2645) 2024-10-03 15:46:58 +00:00
dependency-injection chore: Upgrade matchit to 0.8 (#2645) 2024-10-03 15:46:58 +00:00
diesel-async-postgres examples: Use diesel HasQuery trait (#3519) 2025-10-07 00:13:36 +09:00
diesel-postgres examples: Use diesel HasQuery trait (#3519) 2025-10-07 00:13:36 +09:00
error-handling Fix misplaced comment in error handling example (#3529) 2025-10-11 22:16:47 +02:00
form [test] the form example (#3267) 2025-03-17 13:31:17 +01:00
global-404-handler Remove unused dependencies from examples (#2934) 2024-09-25 03:44:47 -04:00
graceful-shutdown Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
handle-head-request Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService (#3109) 2024-12-27 08:57:52 +01:00
hello-world Add serve function and remove Server re-export (#1868) 2023-04-21 17:45:31 +02:00
http-proxy Make clippy happy (#3350) 2025-09-28 19:15:42 +02:00
jwt examples: Update to jsonwebtoken 10 (#3520) 2025-10-07 13:19:27 -04:00
key-value-store Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService (#3109) 2024-12-27 08:57:52 +01:00
low-level-native-tls remove unused dep in tls examples (#3411) 2025-07-17 12:51:12 +00:00
low-level-openssl remove unused dep in tls examples (#3411) 2025-07-17 12:51:12 +00:00
low-level-rustls remove unused dep in tls examples (#3411) 2025-07-17 12:51:12 +00:00
mongodb Update and fix mongo example (#3549) 2025-11-04 11:57:40 +01:00
multipart-form Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
oauth examples: Update to oauth2 5 (#3462) 2025-09-11 15:34:41 +02:00
parse-body-based-on-content-type Replace async_trait with AFIT / RPITIT (#2308) 2024-09-28 21:27:11 +00:00
print-request-response Remove unused dependencies from examples (#2934) 2024-09-25 03:44:47 -04:00
prometheus-metrics examples: Update to metrics-exporter-prometheus 0.18 (#3590) 2025-12-23 06:06:15 +09:00
readme Remove unused dependencies from examples (#2934) 2024-09-25 03:44:47 -04:00
request-id examples: Update to tower-http 0.6 (#3466) 2025-09-12 13:44:24 +02:00
reqwest-response Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
reverse-proxy Update to cargo-deny api version 2 (#3475) 2025-09-28 19:41:46 +02:00
routes-and-handlers-close-together Add serve function and remove Server re-export (#1868) 2023-04-21 17:45:31 +02:00
serve-with-hyper Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService (#3109) 2024-12-27 08:57:52 +01:00
simple-router-wasm Reorder some TOML sections (#3360) 2025-05-25 08:46:05 +02:00
sqlx-postgres Replace async_trait with AFIT / RPITIT (#2308) 2024-09-28 21:27:11 +00:00
sse Make clippy happy (#3350) 2025-09-28 19:15:42 +02:00
static-file-server Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService (#3109) 2024-12-27 08:57:52 +01:00
stream-to-file Reduce dependency on futures-util (#3358) 2025-05-25 09:39:35 +02:00
templates examples: Update to askama 0.15 (#3593) 2025-12-23 08:11:48 +09:00
templates-minijinja Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
testing Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService (#3109) 2024-12-27 08:57:52 +01:00
testing-websockets Update to tokio-tungstenite 0.28 (#3497) 2025-09-28 19:31:58 +02:00
tls-graceful-shutdown Deprecate Host and Scheme extractors 2025-12-26 14:48:47 +01:00
tls-rustls Deprecate Host and Scheme extractors 2025-12-26 14:48:47 +01:00
todos Replace custom BoxCloneService struct with tower::util::BoxCloneSyncService (#3109) 2024-12-27 08:57:52 +01:00
tokio-postgres examples: Upgrade bb8-postgres deps (#3072) 2024-12-09 22:36:47 -05:00
tokio-redis examples: Update to redis 1 (#3528) 2025-12-06 23:49:47 +09:00
tracing-aka-logging Upgrade most example dependencies (#2936) 2024-09-27 18:50:52 +02:00
unix-domain-socket Make clippy happy (#3350) 2025-09-28 19:15:42 +02:00
validator examples: Update to thiserror 2 (#3522) 2025-10-08 23:19:41 +09:00
versioning [test] the versioning example (#3275) 2025-03-18 10:54:02 +01:00
websockets Update to tokio-tungstenite 0.28 (#3497) 2025-09-28 19:31:58 +02:00
websockets-http2 examples: Update to axum-server 0.7 (#3467) 2025-09-12 15:18:33 +02:00
Cargo.lock ci: Require up-to-date workspace in more places (#3604) 2025-12-27 20:38:51 +00:00
Cargo.toml Split examples & check minimum versions (#3370) 2025-12-02 22:24:37 +01:00
README.md Grammar: Fix "it's" vs "its" in several places (#2518) 2024-01-15 21:48:11 +01:00

Examples

This folder contains numerous examples showing how to use axum. Each example is setup as its own crate so its dependencies are clear.

For a list of what the community built with axum, please see the list here.