Skip to content

Add per-request AI usage event export proposal - #2424

Open
shiv4289 wants to merge 5 commits into
envoyproxy:mainfrom
shiv4289:shiv/usage-events-proposal-v4
Open

Add per-request AI usage event export proposal#2424
shiv4289 wants to merge 5 commits into
envoyproxy:mainfrom
shiv4289:shiv/usage-events-proposal-v4

Conversation

@shiv4289

@shiv4289 shiv4289 commented Jul 25, 2026

Copy link
Copy Markdown

Description

This PR proposes normalized per-request AI usage event export through an acknowledged HTTP sink. It defines the event schema, configuration, observability, deployment topology, and implementation plan while keeping the gateway stateless and the feature disabled by default.

Related Issues/PRs (if applicable)

  1. Here is a draft PR introducing per-request AI usage event export through an acknowledged HTTP sink.
  2. An implementation of the Apache Kafka sink behind this HTTP interface
  3. An implementation of the NATS Jetstream sink behind this HTTP interface

Special notes for reviewers (if applicable)

This PR contains the proposal only. Feedback on the sink abstraction, event schema, and synchronous publication trade-off is especially welcome. Given this is my first work in this repo, let me know if there are parts that need more work.

Define an acknowledged, stateless export path for normalized per-request usage events.

Co-authored-by: Cursor <cursoragent@cursor.com>
@shiv4289
shiv4289 requested a review from a team as a code owner July 25, 2026 03:44
@dosubot dosubot Bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Jul 25, 2026
@shiv4289 shiv4289 changed the title add per-request AI usage event export proposal Add per-request AI usage event export proposal Jul 25, 2026
shiv4289 and others added 4 commits July 28, 2026 00:24
Explain how other gateways handle spend tracking and keep retries and buffering as future options.

Co-authored-by: Cursor <cursoragent@cursor.com>
Group design details under a clear hierarchy and simplify configuration documentation.

Co-authored-by: Cursor <cursoragent@cursor.com>
Keep the proposal focused on the Envoy AI Gateway design and its alternatives.

Co-authored-by: Cursor <cursoragent@cursor.com>
Signed-off-by: Shivji Kumar Jha <shiv.jha@nutanix.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant