Skip to content

feat: observability rate limiting error envelope#682

Draft
rachealkenny wants to merge 1 commit into
Pulsefy:mainfrom
rachealkenny:feature/observability-rate-limiting-error-envelope
Draft

feat: observability rate limiting error envelope#682
rachealkenny wants to merge 1 commit into
Pulsefy:mainfrom
rachealkenny:feature/observability-rate-limiting-error-envelope

Conversation

@rachealkenny

Copy link
Copy Markdown
Contributor

Implement request correlation propagation, standardized error envelope, and configurable rate limiting

Overview

This PR adds request correlation propagation for distributed tracing, standardizes error responses across all controllers, and implements configurable rate limiting per endpoint group.

Changes

Request Correlation Propagation (#557)

  • Propagate correlation IDs to AI-service, onchain adapter, and all external HTTP calls
  • Ensure correlation ID appears consistently in all logs for traceability

Standardized Error Envelope (#556)

  • Implement consistent error envelope across all endpoints: { code, message, correlationId, details }
  • Align existing endpoints to the new format
  • Add E2E tests validating at least 3 representative error cases

Rate Limit Policy Map (#551)

  • Make rate limiting configurable per endpoint group (public, admin, webhooks)
  • Centralize configuration with sane defaults and environment-aware overrides for testnet
  • Add tests covering guard behavior on key endpoints

Files Added

  • Correlation ID propagation middleware
  • Error envelope formatter and exception handler
  • Rate limit configuration map

Files Modified

  • HTTP client for outbound calls
  • All controller error responses
  • Rate limiting middleware

Closes #557
Closes #556
Closes #551

@vercel

vercel Bot commented Jun 28, 2026

Copy link
Copy Markdown

@rachealkenny is attempting to deploy a commit to the Cedarich's projects Team on Vercel.

A member of the Team first needs to authorize it.

@rachealkenny rachealkenny marked this pull request as draft June 28, 2026 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant