> For the complete documentation index, see [llms.txt](https://docs.guardrail.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.guardrail.ai/getting-started/how-it-works.md).

# How It Works

Guardrail's platform connects to EVM RPC nodes with archive and tracing support. We index every transaction in real-time and run your configured guards against relevant state changes.

<figure><img src="/files/eNCb9elgLKqEjE9kxBwz" alt=""><figcaption></figcaption></figure>

## Architecture Overview

{% @mermaid/diagram content="flowchart LR
A\[Blockchain<br/>RPC Node] --> B\[Guardrail<br/>Indexer]
B --> C\[Your Alert<br/>Channels]
B --> D\[Guard<br/>Processors]" %}

**Indexer** — Subscribes to new blocks and indexes transactions with full trace data. Supports archive queries for historical state.

**Guard Processors** — Stateless checks that evaluate transactions against your configured rules. Each guard has trigger conditions (when to run) and alert conditions (when to notify).

**Response System** — Delivers alerts to your channels and can trigger automated responses like contract pauses or webhook calls.

## Detection Speed

Guards trigger on transaction confirmation. Alert delivery is typically under 1 second from block finality. For chains with fast block times, this means near-instant detection.

## What Makes Us Different

**Custom over generic** — Other tools send generic alerts. We build monitoring that understands your protocol's unique risks, economic model, and business logic.

**Full trace access** — We analyze the complete execution path of transactions, including internal calls, not just top-level events.

**Simulation support** — Test guards against historical transactions before deploying. Replay any transaction to see what would have triggered.

***


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.guardrail.ai/getting-started/how-it-works.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
