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

# ADR-013 — Ingestion Pipeline: Fast-Ack + Queue + Idempotent Processor

> POST /v1/core/track|identify|batch: authenticate → Zod validate → Upstash rate-limit → enqueue (QueuePort) → 202 with event id. p95 <100 ms.

Status: Proposed · Refs: DEC-D7, DEC-B8

## Decision

`POST /v1/core/track|identify|batch`: authenticate → Zod validate → Upstash rate-limit → enqueue (QueuePort) → 202 with event id. p95 \<100 ms. Processor (idempotent via processed\_jobs + event idempotency\_key): identity resolution/upsert → append to partitioned `core.tracked_events` → incremental segment evaluation → rules engine matching → effects → outbox. Colocation Vercel↔Supabase region; pooled connections (transaction mode); hot attributes promoted to columns; partition-key predicates mandatory.

## Consequences

* Ingestion latency independent of processing cost; backpressure via queue depth. − Read-after-write is eventual (documented: track responses are 202, not 200).
