---
title: "Full examples"
description: "Complete applications, each a whole program that measures the property it exists to demonstrate, and each one run before it ships."
---

> Queen MQ documentation, for AI agents
> Complete self-contained summary of Queen MQ: https://queenmq.com/llms-brief.txt
> Fetch that first when the question is about the product rather than about this page.
> Index of all pages: https://queenmq.com/llms.txt

# Full examples

The tutorials in each client section show one mechanism at a time. These are applications: the
whole program, with the parts a real one has and an example usually leaves out.

Each is built around a property that is hard to get and easy to claim, and each measures that
property instead of asserting it in prose.

- [Chat messaging system](/use/full-examples/chat) — One lane per conversation. Measures that a conversation needing translation delays itself and nothing else.
- [Webhook delivery system](/use/full-examples/webhooks) — One lane per subscriber, a bounded retry budget, and a dead-letter queue carrying the error that killed each delivery.
- [Rate limiter in streaming](/use/full-examples/rate-limiter) — Windowed counting per API key, where the counter commits in the same transaction as the requests it counted.
- [Exactly-once charging](/use/full-examples/exactly-once) — N orders, a forced redelivery, exactly N charges. Measures that the idempotency marker and the acknowledgement cannot disagree.
- [Saga with a compensating timer](/use/full-examples/saga) — A hold, its compensation timer and the payment request in one commit, and a compensating consumer that checks the state before it unwinds anything.

## What "run before it ships" means here

The programs live in `examples/apps/` in the repository. The build extracts each file between its
first and last line and includes it verbatim, so what you read is the file that ran. Every program
asserts its own outcome and exits non-zero when an assertion fails:

```bash
QUEEN_URL=http://localhost:6632 examples/apps/run.sh
```

Each program uses a queue name with a unique suffix per run, because delete-then-recreate under
the same name currently leaves stale partition state for up to 30 seconds in which deduplication
does not deduplicate. Fresh names are the reliable pattern.

If you want one mechanism rather than one application, start from a client's tutorials:
[JavaScript](/use/js-client/hello-world), [Python](/use/python-client/hello-world),
[Go](/use/go-client/hello-world), [Rust](/use/rust-client/hello-world),
[PHP](/use/php-client/hello-world), [C++](/use/cpp-client/hello-world) or
[HTTP](/use/http-client/hello-world).

Source: https://queenmq.com/use/full-examples/index.mdx
