> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aiaxoniq.com/llms.txt
> Use this file to discover all available pages before exploring further.

# How aiAxonIQ works

> What happens to a span, log line or metric sample between your service and the dashboard — and the two rules that follow from it.

aiAxonIQ ingests OpenTelemetry logs, metrics and traces, plus Prometheus
remote-write. You point an exporter at an endpoint, authenticate with a license
key, and the data becomes queryable in the dashboard.

This page describes the path your data actually takes. It is worth five minutes
because two properties of that path — where your tenant is stamped, and which
store answers which question — explain most of what you will run into later.

## The write path

Every signal follows the same five steps.

<Steps>
  <Step title="Your service exports over OTLP">
    An OpenTelemetry SDK or collector exports to the aiAxonIQ **receiver**.
  </Step>

  <Step title="The receiver authenticates and stamps">
    It validates your license key, applies rate limits, and stamps every record
    with your tenant ID.
  </Step>

  <Step title="Records are queued">
    Published to a durable log, partitioned by tenant.
  </Step>

  <Step title="A worker batches and writes">
    Records land in **ClickHouse**, the telemetry store. Logs are additionally
    indexed into **OpenSearch** for full-text search.
  </Step>

  <Step title="Rollups are maintained as data lands">
    Materialised views roll metrics up into one-minute and one-hour tables, so
    a query over a long window does not scan raw samples.
  </Step>
</Steps>

The receiver returns **202 Accepted** as soon as the batch is queued. That is an
acknowledgement of receipt, not of storage — a `202` means your data is in the
pipeline, and it becomes queryable a short time later once the worker has
flushed a batch.

<Note>
  **Why your first data can take a moment to appear.** Workers batch before
  writing, flushing when a batch fills or after a few seconds — whichever comes
  first. A single test span is in the small-batch case, so give it a few seconds
  before concluding something is wrong.
</Note>

## Your tenant ID is assigned, never sent

The receiver derives your tenant from the license key on the request and stamps
it onto every record. Nothing your SDK sends can set or change it.

This matters in one practical way: **there is no attribute you can add to route
data into a different tenant.** If you want to separate staging from production,
separate them with a resource attribute such as `deployment.environment` and
filter on it at query time, or use two accounts. Sending a `tenant.id` attribute
does nothing.

## Which store answers which question

You do not query these directly — the dashboard and API do it for you — but
knowing the split explains why some queries offer options others do not.

<CardGroup cols={3}>
  <Card title="ClickHouse" icon="database">
    Logs, spans and metric samples. Backs the Logs Explorer, traces, metrics and
    every dashboard chart. Supports field filters and boolean operators.
  </Card>

  <Card title="OpenSearch" icon="magnifying-glass">
    A full-text index of your logs, per tenant, per day. Backs the fuzzy
    log-search API.
  </Card>

  <Card title="PostgreSQL" icon="table">
    The control plane — your account, users, alert rules, dashboards and
    license-key metadata. No telemetry lives here.
  </Card>
</CardGroup>

The consequence worth remembering: log search and the Logs Explorer are backed
by different engines with different query languages. The syntax documented in
[Searching logs](/guides/logs/search) is the Logs Explorer's.

## What you need to send data

Three things, in order.

1. A **license key** — created in the dashboard, sent as the `X-License-Key`
   header. See [Create a license key](/get-started/license-keys).
2. An **endpoint** — the receiver's OTLP/HTTP address. See
   [Send data with OpenTelemetry](/send-data/otel/collector).
3. An **exporter** — any OpenTelemetry SDK or the OpenTelemetry Collector.
   aiAxonIQ speaks standard OTLP, so there is no aiAxonIQ-specific SDK to
   install and nothing to rewrite if you later point the same exporter
   somewhere else.

### Placeholders used throughout these docs

| Placeholder          | What to substitute                                             |
| :------------------- | :------------------------------------------------------------- |
| `$OIQ_ENDPOINT`      | Your OTLP/HTTP base URL, from **Get Started** in the dashboard |
| `$OIQ_GRPC_ENDPOINT` | Your OTLP/gRPC address, also on **Get Started**                |
| `$OIQ_LICENSE_KEY`   | A key from **Settings → License Keys**, starting `oiq_`        |
| `<your-domain>`      | Your own domain, for self-hosted deployments                   |

<Info>
  Values marked above differ per deployment, which is why no single URL appears
  in these pages. **Get Started** in the dashboard renders the ones that are
  correct for yours.
</Info>

## Next

<CardGroup cols={2}>
  <Card title="Create a license key" icon="key" href="/get-started/license-keys">
    The credential every ingest request carries.
  </Card>

  <Card title="Send data with OpenTelemetry" icon="telescope" href="/send-data/otel/collector">
    Endpoints, headers, and a first request.
  </Card>
</CardGroup>
