Z
Zirnay Documentation v2.4.1
System One Intelligence โ€ข AI Infrastructure for Decisions
Launch Playground โ†— Interactive API Explorer Strands Decider โ†—
DOCS / PRODUCTION OPERATIONS / Observability, Security & Telemetry

Observability, Security & Telemetry

Prometheus metrics export, IP whitelisting security perimeters, structured JSON audit logs, and Stripe metered billing.

โฑ 5 min read โ€ข Zirnay v2.4.1 โ€ข Updated October 2026

Observability, Security & Metrics Telemetry

Production System One models require sub-millisecond SLI monitoring and perimeter IP protection.

1. Prometheus Metrics Specification

Zirnay exports standardized metrics formatted for Prometheus and OpenTelemetry collectors:

METRIC NAME TYPE LABELS DESCRIPTION
daas_decision_requests_total Counter org_slug, team_slug, model_slug, outcome, status Cumulative total of decision executions processed.
daas_decision_duration_seconds Histogram org_slug, team_slug, model_slug, cache_state Latency distribution (buckets from 200ยตs to 100ms).
daas_checkpoint_cache_requests_total Counter team_slug, model_slug, result In-memory LRU page cache hits vs misses.
daas_memory_mapped_bytes Gauge model_slug, checkpoint_id Resident memory (RAM) used by mmap checkpoints.
daas_meter_events_queued_total Counter org_slug, status Decision billing events queued for Stripe sync.

2. Perimeter IP Whitelisting Rule

To prevent external reconnaissance, the /metrics endpoint enforces strict IP whitelisting rules at both the Nginx reverse proxy and Express application layers:

๐Ÿ›ก๏ธ Access Control Policy: By default, only loopback (127.0.0.1, ::1) and internal RFC 1918 private subnets (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16) are authorized to scrape metrics. All non-whitelisted external IP traffic is blocked with HTTP 403 Forbidden and logged to security audit logs.

Custom monitoring IPs can be whitelisted via the backend environment variable:

Environment Configuration
# Whitelist specific external Prometheus scraper IPs or CIDR blocks:
METRICS_ALLOWED_IPS="203.0.113.195,198.51.100.0/24"

3. Structured JSON Audit Logging with PII Redaction

All decisions and control plane actions generate structured JSON logs with automatic PII masking (masking IP addresses and cardholder PAN numbers before stdout ingestion):

Audit Log Event
{
  "timestamp": "2026-10-10T19:10:36.000Z",
  "level": "INFO",
  "service": "zirnay-daas-engine",
  "message": "Decision executed successfully",
  "model_slug": "laya-card-auth",
  "decision": "APPROVE",
  "latency_ms": 1.82,
  "client_ip": "192.168.***.***",
  "card_number": "************4242"
}