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

# What is LiteJoin?

> Turn any API into a real-time stream. Join data with SQL. Deploy as a single binary.

# What is LiteJoin?

LiteJoin is a **real-time streaming engine** that lets developers turn any REST API into a live event stream, join data across sources with standard SQL, and deploy the entire pipeline as a single binary. No Kafka. No JVM. No cluster to manage.

<CardGroup cols={2}>
  <Card title="API → Stream" icon="bolt">
    Point LiteJoin at any REST API. It polls, diffs, and emits only the changes — turning request/response into real-time events automatically.
  </Card>

  <Card title="SQL Joins" icon="code">
    Write familiar `SELECT ... JOIN` queries to combine data from multiple streams. LiteJoin evaluates joins in real-time as new data arrives.
  </Card>

  <Card title="Single Binary" icon="cube">
    The entire engine — storage, joins, windows, sinks — ships as one Go binary backed by SQLite. No external dependencies.
  </Card>

  <Card title="LiteJoin Studio" icon="desktop">
    A visual desktop app for building pipelines. Add sources, write SQL, see live results, and export a production-ready config file.
  </Card>
</CardGroup>

## Why LiteJoin?

Stream processing has historically required heavy infrastructure: Kafka for messaging, Flink or ksqlDB for processing, and a team to keep it running. Most developers just need to:

1. **Watch an API for changes** — "Tell me when a Stripe charge status changes"
2. **Enrich with context** — "Join that charge with customer data from another API"
3. **React in real-time** — "Send the enriched result to a webhook or dashboard"

LiteJoin does all three with a YAML config file and a single command:

```bash theme={null}
litejoin run -c litejoin.yaml
```

## How It Works

```yaml theme={null}
# litejoin.yaml — a complete pipeline
sources:
  - name: stripe_charges
    type: api
    topic: charges
    api:
      url: "https://api.stripe.com/v1/charges?limit=100"
      interval: 10s
      key_path: "id"
      response_path: "data"
      headers:
        Authorization: "Bearer ${STRIPE_SECRET_KEY}"

  - name: stripe_customers
    type: api
    topic: customers
    api:
      url: "https://api.stripe.com/v1/customers?limit=100"
      interval: 5m
      key_path: "id"
      response_path: "data"
      headers:
        Authorization: "Bearer ${STRIPE_SECRET_KEY}"

joins:
  - name: charge-customer-join
    query: |
      SELECT
        c.key as charge_id,
        c.payload as charge,
        cust.payload as customer
      FROM charges c
      LEFT JOIN customers cust
        ON json_extract(c.payload, '$.customer') = cust.key
      WHERE c.timestamp > (strftime('%s', 'now') - 60)
    sink: webhook_out

sinks:
  - type: http
    name: webhook_out
    config:
      url: "http://localhost:9000/webhook"
```

LiteJoin polls both APIs, detects changes (new charges, updated customers), joins them in real-time using SQL, and forwards enriched results to your webhook.

## Use Cases

| Scenario               | How LiteJoin Helps                                                      |
| ---------------------- | ----------------------------------------------------------------------- |
| **Payment enrichment** | Poll Stripe charges + customers → joined stream with full context       |
| **DevOps dashboards**  | Poll GitHub PRs + Jira tickets → velocity metrics joined on branch name |
| **Price monitoring**   | Poll competitor pricing APIs → detect and alert on changes              |
| **IoT correlation**    | Ingest sensor data via HTTP → window + aggregate in real-time           |
| **Audit trails**       | Capture every API state change with field-level diff metadata           |

## Next Steps

<CardGroup cols={2}>
  <Card title="Quickstart" icon="rocket" href="/getting-started/quickstart">
    Install LiteJoin and run your first pipeline in 5 minutes.
  </Card>

  <Card title="Core Concepts" icon="book" href="/core-concepts">
    Understand sources, streams, joins, windows, and sinks.
  </Card>
</CardGroup>
