Getting Started
G8KEPR is a hosted service — nothing to install
Create your account
Sign up at app.g8kepr.com/auth/signup with email + password, or single sign-on via Google, GitHub, or Microsoft. A 30-day Starter trial (extend to 90 days free) is provisioned automatically — no credit card required.
Create an API key
In the dashboard, open Dashboard → API Keys (/dashboard/api-keys) and create a key. Keys are formatted gk_org_<org8>_<token> and are shown only once at creation — copy it somewhere safe. Each key carries a scope: read, write, or admin. Send it either as Authorization: Bearer <key> or as an X-API-Key: <key> header.
Connect an LLM provider (BYOK)
Before completions will work, add your own upstream provider key (for example your OpenAI or Anthropic key) under Dashboard → AI Gateway → Providers. Bring-your-own-key means G8KEPR uses your key to reach the model, so your provider spend and data stay on your own account.
Required before your first completion
Send your first request
POST to the gateway completions endpoint with your API key as a Bearer token. provider, model, and messages are the essentials; max_tokens, temperature, stream, tools, conversation_id, and sources (for RAG grounding) are optional.
curl -X POST https://api.g8kepr.com/api/v1/gateway/completions \
-H "Authorization: Bearer gk_org_ab12cd34_YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"provider": "openai",
"model": "gpt-4o-mini",
"messages": [
{ "role": "user", "content": "Hello, G8KEPR!" }
]
}'The gateway returns its own response envelope — content is a top-level string. This is not the OpenAI response shape, so it is not a drop-in base_url swap.
{
"request_id": "req_9f2c8ab1",
"provider": "openai",
"model": "gpt-4o-mini",
"content": "Hello! How can I help you today?",
"finish_reason": "stop",
"usage": { "prompt_tokens": 12, "completion_tokens": 9, "total_tokens": 21 },
"cost_usd": 0.0000042,
"latency_ms": 512,
"verification": null,
"response_filter": null
}See your results
Open Dashboard → AI Gateway for request Analytics and Costs, and Dashboard → Security for any threats detected on your traffic.
Plans & billing
Every account starts on a 30-day Starter trial (extend to 90 days free). Upgrade, downgrade, or add payment details anytime under Dashboard → Billing.
| Plan | Price | Findings / mo | Highlights |
|---|---|---|---|
| Community | $0 | 100K | 1 sensor |
| Starter | $399 / mo | 1M | All 4 pillars · 3 sensors |
| Pro | $1,499 / mo | 10M | All 4 pillars · SIEM · BYOK + Platform gateway |
| Enterprise | Contact Sales | Unlimited | SSO/SAML · BAA/DPA · on-prem / air-gap |
Self-Hosted & Enterprise (contact sales)
Architecture Overview
Customer-VPC Topology
Customer-VPC Topology (v1 self-hosted)
Everything inside the dashed border runs in the customer's own network. G8KEPR has no inbound access.
Sensors (stateless, independent, per-detector class)
9 detectors: tool poisoning, compound, prompt injection
Prompt injection (DeBERTa) + Presidio PII redactor
5 layers, EU AI Act Article 5/13/14/15 enforcement
verify sig
Ed25519 · JCS
dedup
24h Redis cache
compound corr.
5-min window
audit chain
HMAC hash-chain
Customer-owned data plane
Operator surface
Built-in auth (TOTP) + OIDC opt-in · 4 RBAC roles
What G8KEPR runs (outside your VPC)
Pattern-pack mirror
releases.g8kepr.com — signed bundles
License issuance
licenses.g8kepr.com — Ed25519 JWS
Telemetry endpoint
opt-in only · default OFF
Air-gap deploys never touch any of the above. License + pattern packs delivered out-of-band.
Wire Format Flow
Wire Format Flow
How a single threat finding gets from a sensor pod to the dashboard, end-to-end.
Detector matches pattern (e.g. tool_poisoning)
CloudEvents 1.0 + specversion, subject=correlation_id
JCS (RFC 8785) → Ed25519 sig + nonce
Online → POST /findings · offline → disk spool (24h max)
5. Verify sig
Ed25519 + sensor cert · reject on mismatch
6. Schema check
Accept N or N-1 · reject N+1 with wire_version_unsupported
7. Dedup
Redis cache, 24h TTL per idempotency_key
8. Compound corr.
5-min sliding window · 5 named patterns
9. Persist + audit
threat_events + HMAC hash chain
threat_events, audit_log, mcp_sessions — RLS enforced
Live page reads from Postgres on mount + window focus (no polling)
Failure-mode contracts
- parse_error · sensor still emits a finding so audit trail is intact
- collector_unreachable · sensor spools to disk, replays on reconnect at 100/s
- spool_full · low/medium severity dropped first; critical always preserved
- clock_skew > 30s · finding accepted, audit warning logged, NTP recommended
Sensor ↔ Collector Contract
Sensors are stateless; the collector is the only stateful component and the only thing that touches Postgres or Redis. Every interaction between the two is on this diagram — anything not listed does not happen (per ADR-002).
Sensor ↔ Collector Contract
Every interaction between the two halves. Anything not on this list does not happen.
Owns
- Detector logic (regex / ML / heuristic)
- Ed25519 signing (its mTLS cert key)
- Disk spool (500MB / 24h max, per ADR-015)
- Per-pod identity (instance_id in PVC)
Never touches
- · Customer Postgres / Redis
- · Other sensors (no peer awareness)
- · License signing key
POST /sensors/register
ADR-012identity + capabilities + version
on boot
POST /sensors/heartbeat
ADR-012load · queue depth · last-finding-ts
every 30s
POST /findings (mTLS · CloudEvents · Ed25519 sig)
ADR-003single or /findings/batch · max 100 per batch
on every detection
GET /sensors/{id}/config
ADR-006pulls latest config when SIGHUP missed
on reload signal
replay_rate_limit response
ADR-015envelopes/sec · default 100
after partition
4xx ingest reject
ADR-003wire_version_unsupported · sig_invalid · license_expired
on policy violation
remote config push (rare)
ADR-006mute pattern · raise severity threshold · pause sensor
operator action
Owns
- License + CRL verification
- Dedup cache (Redis, 24h TTL)
- Compound correlation (5-min window)
- Hash-chain audit log (HMAC-keyed)
Also serves
- · Dashboard ingress (Next.js, ADR-019)
- · Postgres writes (RLS-enforced)
- · Sensor inventory page
v1 contract. v2 adds: collector HA via leader election, sensor-to-sensor mesh for compound early-emit, customer-built sensor SDK (ADR-013).
Deployment Shapes
Kubernetes (Helm)
The recommended production path. Umbrella chart deploys collector + per-sensor sub-charts. cert-manager handles mTLS.
Docker Compose
Single-host installs (lab, demo, small SOC). step-ca sidecar replaces cert-manager. Brief downtime on upgrade.
Air-gap (offline)
Zero outbound. Pattern packs and license delivered via signed bundle. Telemetry default-OFF aligns naturally.
Docker Compose layout
Docker Compose Layout — single host
For lab, demo, or small SOC. step-ca replaces cert-manager. Brief downtime on upgrade.
step-ca
smallstep/step-ca · issues 24h sensor certs · CA root in volume
License + secrets
./secrets/license.lic · .env (DATABASE_URL, REDIS_URL)
image: g8kepr/sensor-mcp@sha256
vol: spool · 500Mi
image: g8kepr/sensor-ai@sha256
vol: spool · 500Mi
image: g8kepr/sensor-vfn@sha256
vol: spool · 500Mi
image: g8kepr/collector@sha256 · single replica
DATABASE_URL=postgresql://…
Not in compose. You provide the connection string.
REDIS_URL=redis://…
Optional same-host redis container for demo only.
Kubernetes / Helm layout
Kubernetes Layout — umbrella Helm chart
Single namespace · one collector + per-sensor sub-charts · cert-manager handles mTLS.
cert-manager Issuer
customer-private CA · 24h cert lifetime · auto-rotate
Ingress (dashboard)
g8kepr.acme.internal · TLS · OIDC or built-in auth
charts/sensor-* sub-charts (per-detector class)
Deployment · 1 replica · HPA off (v1)
PVC: 500Mi (spool)
Deployment · 1 replica · HPA off (v1)
PVC: 500Mi (spool)
Deployment · 1 replica · GPU optional
PVC: 500Mi (spool)
charts/collector sub-chart
verify sig
dedup 24h
compound 5min
audit chain
+ Migration Job (Alembic) runs once at install · ServiceMonitor for Prometheus
External services (customer-owned, NOT in chart)
RDS · Cloud SQL · in-cluster operator · bare metal
existingSecret: g8kepr-db
Elasticache · Memorystore · in-cluster · external
existingSecret: g8kepr-redis
Umbrella chart: g8kepr/g8kepr
charts/collector + charts/sensor-mcp + charts/sensor-ai-gateway + charts/sensor-verification — one helm release, four sub-deployments.
Detection Capabilities
Coverage Map
What lands across the four pillars. Categorical inventory only — specific patterns, scoring weights, and evasion countermeasures are not publicly enumerated. Licensed customers see the full pattern catalog in the dashboard pattern library.
78,000+
threat patterns
24 categories · weekly OSS sync
5
compound chains
multi-vector named patterns
14
LLM providers
cost-aware routing
14
compliance frameworks
+ 9 reference · EU AI Act · HIPAA · SOC 2
OWASP Top 10 + WAF
API SecuritySQL injection · XSS · path traversal · command injection · SSRF · auth bypass · mass assignment · JWT manipulation
ML detector · 78K+ samples · 24 categories
Shadow & zombie APIs
API SecurityDetects undocumented endpoints from live traffic · flags deprecated routes still in use
Bot detection
API SecurityBehavioral baseline · TLS / JA3 fingerprint · credential stuffing · scraping cadence
Tool poisoning
MCP SecuritySchema-hash diff between registered tool definition and runtime invocations — catches rug-pull mutations
Compound exploit chains
MCP SecurityLethal Trifecta · Credential Exfil Chain · Obfuscated Execution · Phishing Tool · Shadow Egress
5 named multi-vector patterns
Prompt injection
MCP SecurityDirect + jailbreak families · LLM-2026 patterns (Crescendo · Skeleton Key · DAN) · Unicode / leet / base64 normalization
Multi-provider routing
AI Gateway14 providers across four tiers · cost-aware routing · per-provider circuit breakers
14 LLM providers
PII redaction
AI GatewayMicrosoft Presidio integration · email · IP · SSN · credit-card · medical record · custom recognizers
Cost anomalies
AI GatewayPer-org budget caps · token-spend spikes · provider-skew alerts · 22+ pre-built breakers
Output validation (4 layers)
VerificationIntegrity · grounding · structural · constraint — applied to every AI-generated response before it reaches the client
4-layer pipeline
EU AI Act enforcement
VerificationArticle 5 (prohibited practices) · Article 13 (transparency) · Article 14 (oversight) · Article 15 (accuracy)
4 articles wired
Drift & manipulation
VerificationCross-turn memory poisoning · fabricated-history detection · permission drift · system-prompt subversion
Categories shown — specific patterns, scoring weights, and evasion countermeasures are not publicly enumerated. Full pattern catalog is accessible to licensed customers via the dashboard's pattern library page.
Pattern Updates
The base pattern set ships with the sensor images. Updates arrive as signed bundles — verified against G8KEPR's Ed25519 release key before load. Online deploys pull weekly from releases.g8kepr.com; air-gap deploys receive packs out-of-band via signed file. Sensor pins min/max pack version in sensor.yaml so production stays stable across releases.
Critical (zero-day)
Out-of-band drop · daily check · auto-applied
Routine
Weekly cadence · additive only · semver minor
Major
With sensor minor bump · breaking schema noted in CHANGELOG
Compound Chains
Multi-vector attacks where each individual primitive looks benign — only the co-occurrence is lethal. The collector correlates atomic findings across a 5-minute sliding window per request and emits a compound finding when a named pattern matches.
Lethal Trifecta
Prompt-injection susceptibility + outbound network + filesystem access on a single tool surface. The canonical agentic exploit shape.
Credential Exfiltration Chain
Reads environment secrets or credential stores AND has outbound network egress. Skill reads $AWS_SECRET_KEY then POSTs to a webhook — same tool.
Phishing Tool
Tool description encourages credential requests combined with prompt-injection susceptibility. "To continue, please paste your password."
Obfuscated Execution
Encoded payloads (base64 / hex) combined with shell exec or eval. Hidden command behind decode + exec.
Shadow Egress
Outbound domain referenced is encoded or obfuscated rather than declared as a literal. URL constructed at runtime to evade allowlist review.
Compliance Mapping
Detection findings feed compliance evidence tooling. HIPAA is the only framework with live-evidence scoring today; the others (SOC 2, ISO 27001, PCI DSS, GDPR, EU AI Act, and more) are self-attestation and gap-analysis mapping — never marked certified until independently attested.
Compliance Control Mapping
Gap-analysis coverage of mapped controls — not an attestation. HIPAA is the only framework with live-evidence scoring; others are self-attestation / gap-analysis tooling.
API Security
Example Request Monitor
HTTP Integration
Direct HTTP Integration
api.g8kepr.com/v1OpenAI-compatiblepip install g8kepr-cliOWASP Top 10 Coverage
Broken Access Control
Cryptographic Failures
Injection
Insecure Design
Security Misconfiguration
Vulnerable Components
Auth & Identity Failures
Data Integrity Failures
Security Logging Failures
SSRF
Rate Limiting Tiers
| Plan | Req / min | Req / day | Burst | Concurrent |
|---|---|---|---|---|
| Free | 60 | 10,000 | 10 | 5 |
| Pro | 1,000 | 500,000 | 200 | 50 |
| Enterprise | Unlimited | Unlimited | 5,000 | Unlimited |
Geo-Blocking Config
{
"rule_name": "block-high-risk-countries",
"action": "block",
"countries": ["CN", "RU", "KP", "IR"],
"response_code": 403,
"log": true
}Rate limit headers
X-RateLimit-Limit, X-RateLimit-Remaining, and Retry-After on 429. Implement exponential backoff — start at 1s, double each retry, cap at 32s.MCP Security
MCP Security Flow
Session Tracking
Include X-Session-ID in every request to enable multi-turn threat correlation. G8KEPR tracks escalation patterns across requests within a session.
# All requests in a session share the same X-Session-ID
curl -X POST https://api.g8kepr.com/api/v1/gateway/completions \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "X-Session-ID: sess_abc123xyz" \
-H "Content-Type: application/json" \
-d '{ "model": "gpt-4o", "messages": [...] }'Tool Authorization — RBAC
| Tool Category | viewer | operator | admin | super_admin |
|---|---|---|---|---|
| Read files | ✓ | ✓ | ✓ | ✓ |
| Write files | ✗ | ✓ | ✓ | ✓ |
| Execute code | ✗ | ✗ | ✓ | ✓ |
| Network access | ✗ | ✗ | ✗ | ✓ |
| System calls | ✗ | ✗ | ✗ | ✓ |
Explainability Response
{
"allowed": false,
"threat_score": 0.87,
"decision": "block",
"explanation": "Prompt injection pattern detected: role confusion + instruction override",
"patterns_matched": [
{ "id": "PI-001", "name": "Role Confusion", "confidence": 0.92 },
{ "id": "PI-007", "name": "Instruction Override", "confidence": 0.81 }
],
"session_escalation_factor": 2.0,
"session_request_count": 4
}Agent Hijacking Detection
G8KEPR detects multi-agent attack patterns that target agentic pipelines — attacks designed to manipulate one agent through another, poison tool results, or impersonate orchestrators. Coverage includes context poisoning, cross-session leakage, and multi-step prompt chaining.
| Attack Class | Example Signal | Default Action |
|---|---|---|
| Context Poisoning | Instructions embedded in tool results targeting downstream agents | Block + alert |
| Agent Impersonation | Messages claiming to originate from an orchestrator or master agent | Block + alert |
| Exfiltration via Agent | Requests to serialize context or system prompt into a tool argument | Block + alert |
| Prompt Chaining | Multi-step sequences: extract data → post to external endpoint | Block + alert |
| Sleeper Payload | Instructions that activate on a future keyword or next user message | Block + alert |
Multi-agent pipelines
X-Session-ID across all agent hops. G8KEPR correlates the full chain and can attribute a hijacking attempt to the specific hop where it entered.Audit Log Query
curl https://api.g8kepr.com/api/v1/mcp/audit?session_id=sess_abc123xyz \
-H "Authorization: Bearer YOUR_API_KEY"Session expiry
/api/v1/mcp/sessions/{id}/heartbeat — this resets the 30-minute clock without consuming quota.AI Gateway
AI Gateway - Intelligent Routing
Cost Savings
Uptime
Latency Added
Routing Strategies
Distributes requests evenly across all healthy providers. Good for load balancing when all providers have similar SLAs.
{
"strategy": "round_robin",
"providers": ["openai", "anthropic", "cohere"],
"health_check_interval_s": 30
}Model Marketplace
OpenAI
gpt-4o
gpt-4o-mini
o1
Anthropic
claude-opus-4-6
claude-sonnet-4-6
claude-haiku-4-5
Cohere
command-r-plus
command-r
embed-v3
Streaming
import httpx
with httpx.stream("POST", "https://api.g8kepr.com/api/v1/gateway/completions",
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={"model": "gpt-4o", "messages": [...], "stream": True},
) as resp:
for line in resp.iter_lines():
if line.startswith("data: "):
print(line[6:]) # SSE payloadWebhook Events
Webhook Event Flow
Webhook Payload Schemas
All webhook payloads share a common envelope. Verify the signature using X-G8KEPR-Signature (HMAC-SHA256 of the raw body with your webhook secret).
{
"event": "threat.blocked",
"version": "2.1",
"timestamp": "2026-03-31T14:22:01.432Z",
"org_id": "org_abc123",
"gateway_id": "gw_prod_01",
"data": {
"request_id": "req_xyz789",
"threat_score": 0.91,
"decision": "block",
"pattern_ids": ["PI-001", "PI-007"],
"session_id": "sess_def456",
"session_request_count": 4,
"session_escalation_factor": 2.0,
"source_ip": "1.2.3.4",
"method": "POST",
"path": "/v1/completions",
"user_agent": "python-httpx/0.27.0"
}
}{
"event": "gateway.down",
"version": "2.1",
"timestamp": "2026-03-31T14:30:00.001Z",
"org_id": "org_abc123",
"gateway_id": "gw_prod_01",
"data": {
"gateway_name": "Production",
"backend_url": "https://api.example.com",
"check_type": "http",
"http_status": 503,
"consecutive_failures": 3,
"first_failure_at": "2026-03-31T14:29:00.000Z"
}
}{
"event": "rate_limit.exceeded",
"version": "2.1",
"timestamp": "2026-03-31T15:00:05.210Z",
"org_id": "org_abc123",
"gateway_id": "gw_prod_01",
"data": {
"scope": "per_ip",
"identifier": "1.2.3.4",
"limit": 100,
"window_seconds": 60,
"retry_after": 47
}
}Signature verification
X-G8KEPR-Signature before processing webhook payloads. Use hmac.compare_digest (Python) or crypto.timingSafeEqual (Node) to prevent timing attacks.Delivery Reliability
G8KEPR retries failed webhook deliveries with exponential backoff (±10% jitter). HTTP 4xx responses (except 429 Too Many Requests) are treated as permanent failures and do not retry — fix the endpoint configuration rather than burning retries. Endpoints that fail repeatedly are automatically paused to protect your receiving infrastructure; you can re-enable them from Dashboard → Webhooks or via the API.
| HTTP Status | Behaviour |
|---|---|
| 2xx | Delivery confirmed. Retry counter resets. |
| 429 | Retried with backoff (respects Retry-After if present). |
| 4xx (other) | Marked exhausted immediately — no further retries. |
| 5xx / timeout | Retried up to the configured attempt limit with backoff. |
| Endpoint paused | Repeated failures trigger automatic circuit-break. Re-enable via Dashboard or PATCH /api/v1/webhooks/{id}. |
Inspect failures for a specific webhook:
curl https://api.g8kepr.com/api/v1/webhooks/wh_abc123/failures/summary \
-H "Authorization: Bearer YOUR_API_KEY"Threat Detection
Threat Detection Pipeline
Request received
78K+ samples
Behavioral detection
Rules evaluation
Allow / Block
78,000+
Threat corpus samples
0.804
Held-out recall
0.48%
False-positive rate
Session Escalation Tiers
1 request
1.0×
Baseline score
3 requests
1.3×
Elevated threshold
5 requests
2.0×
High alert
8+ requests
2.5×
Auto-block
Example Threat Log
Response Policies
| Policy | Threshold | Action | Description |
|---|---|---|---|
| Log | 0.2 – 0.4 | Allow + log | Record event for analysis. No impact to request. |
| Alert | 0.4 – 0.6 | Allow + alert | Webhook notification sent. Request continues. |
| Challenge | 0.6 – 0.7 | CAPTCHA / 2FA | User must verify before request is forwarded. |
| Block | ≥ 0.7 | HTTP 403 | Request rejected. Audit log written. |
Auto-block threshold
POST /api/v1/config/thresholds. Lowering it increases false-positive rate; raise it only after reviewing your threat logs.CLI Reference
Command-line tool — coming soon
API Reference
API Key Authentication Flow
Authorization: Bearerscopes, limitsgk_org_live_*Production - Full accessgk_org_test_*Sandbox - No billinggk_org_rstr_*Restricted - Limitedhttps://api.g8kepr.com/api/v1Authentication
Create keys in the dashboard under Dashboard → API Keys. Keys are formatted gk_org_<org8>_<token> and are shown only once at creation. Send a key as an Authorization: Bearer <key> header, or as X-API-Key: <key>. Each key carries a scope: read, write, or admin.
# Bearer token (the X-API-Key: <key> header also works)
curl https://api.g8kepr.com/api/v1/gateways \
-H "Authorization: Bearer gk_org_ab12cd34_YOUR_TOKEN"Endpoints
Rate Limit Response Headers
| Header | Description |
|---|---|
| X-RateLimit-Limit | Maximum requests allowed in the current window |
| X-RateLimit-Remaining | Requests remaining in current window |
| X-RateLimit-Reset | Unix timestamp when the window resets |
| Retry-After | Seconds to wait before retrying (on 429 only) |
Error codes
Retry-After header. 502 [NO_PROVIDERS] — no upstream LLM provider configured; add a provider / BYOK key in the dashboard AI Gateway. 503 Service Unavailable — backend health check failed; retry with backoff.Configuration
Configuration File Structure
g8kepr.yaml.envCompliance Frameworks
Compliance Control Mapping
Gap-analysis coverage of mapped controls — not an attestation. HIPAA is the only framework with live-evidence scoring; others are self-attestation / gap-analysis tooling.
Environment Variables
| Variable | Required | Default | Description |
|---|---|---|---|
| DATABASE_URL | required | — | PostgreSQL connection string |
| REDIS_URL | required | — | Redis connection string for rate limiting & sessions |
| SECRET_KEY | required | — | 32+ char secret for JWT signing |
| API_ENCRYPTION_KEY | required | — | Fernet key for encrypting stored API keys |
| ENVIRONMENT | optional | production | production | staging | development |
| LOG_LEVEL | optional | info | debug | info | warning | error |
| OPENAI_API_KEY | optional | — | Required to use OpenAI via AI Gateway |
| ANTHROPIC_API_KEY | optional | — | Required to use Anthropic via AI Gateway |
| SENTRY_DSN | optional | — | Error monitoring (recommended for production) |
| POSTHOG_API_KEY | optional | — | Analytics (PII-safe — no user content logged) |
| ALLOWED_ORIGINS | optional | * | Comma-separated CORS allowed origins |
| WORKERS | optional | 4 | Uvicorn worker count (set to CPU cores × 2) |
Docker Compose — env injection
services:
backend:
image: g8kepr/api:2.1.0
environment:
DATABASE_URL: $DATABASE_URL
REDIS_URL: $REDIS_URL
SECRET_KEY: $SECRET_KEY
API_ENCRYPTION_KEY: $API_ENCRYPTION_KEY
ENVIRONMENT: production
LOG_LEVEL: info
WORKERS: 4
env_file:
- .env.production # blocked from git by pre-commit hookFeature Flags
| Flag | Default | Effect when enabled |
|---|---|---|
| FEATURE_MCP_SECURITY | true | Enable MCP Security pillar and session tracking |
| FEATURE_AI_GATEWAY | true | Enable AI Gateway routing and marketplace |
| FEATURE_GEO_BLOCKING | false | Enable geo-blocking rules UI and enforcement |
| FEATURE_HIPAA_BAA | false | Show HIPAA BAA module (requires enterprise plan) |
| FEATURE_SOC2_REPORTS | false | Enable SOC 2 compliance reporting tab |
Secrets management
.env.production commits are blocked by the pre-commit hook. Use your cloud provider's secrets manager (AWS Secrets Manager, GCP Secret Manager, Vault) and inject at runtime via env_file or environment variable injection.Troubleshooting
Common Errors
Debug Mode
# Enable verbose logging
LOG_LEVEL=debug g8kepr serve
# Or set in environment
export LOG_LEVEL=debug
docker compose up backendHealth Check Endpoints
| Endpoint | Checks | Use case |
|---|---|---|
| GET /health | Process alive | Load balancer liveness probe |
| GET /health/db | PostgreSQL connectivity + query | Readiness probe, alerting |
| GET /health/redis | Redis PING + latency | Readiness probe, alerting |
| GET /health/full | All of the above + worker queue | Monitoring dashboards |
Enterprise Support
Priority support, SLA, and dedicated Slack channel for Enterprise plans.
Contact sales →Monitoring & Observability
G8KEPR ships with a full observability stack: Prometheus metrics, pre-built Grafana dashboards, and structured JSON logs compatible with any aggregator (Loki, Datadog, ELK).
Prometheus Metrics
Metrics are exposed at GET /metrics in Prometheus text format. Scrape interval recommended: 15s.
| Metric | Type | Description |
|---|---|---|
| g8kepr_requests_total | Counter | Total requests proxied, labeled by gateway, method, status |
| g8kepr_request_duration_seconds | Histogram | End-to-end request latency (p50/p95/p99 available) |
| g8kepr_threats_total | Counter | Threats detected, labeled by decision (block/alert/log) |
| g8kepr_threat_score | Histogram | Distribution of threat scores across all requests |
| g8kepr_rate_limit_hits_total | Counter | Rate limit 429 responses, labeled by scope and gateway |
| g8kepr_session_escalations_total | Counter | Multi-turn session escalation events by tier |
| g8kepr_gateway_health | Gauge | 1=healthy 0=unhealthy, labeled by gateway_id |
| g8kepr_db_pool_size | Gauge | Active / idle PostgreSQL connections |
| g8kepr_redis_latency_seconds | Histogram | Redis command latency |
| g8kepr_ai_tokens_total | Counter | LLM tokens consumed via AI Gateway, labeled by model and provider |
Prometheus Scrape Config
scrape_configs:
- job_name: 'g8kepr'
scrape_interval: 15s
static_configs:
- targets: 'g8kepr-backend:8000'
metrics_path: /metrics
bearer_token: YOUR_METRICS_TOKENGrafana Dashboard Setup
Import the pre-built dashboards from the monitoring/grafana/dashboards/ directory in the repo. Three dashboards are included:
G8KEPR Overview
Request volume, threat rate, gateway health, p95 latency — the oncall dashboard
Threat Intelligence
Threat score distribution, top patterns, session escalations, geo heatmap
AI Gateway
Token consumption, cost by model/provider, routing distribution, error rates
# Import via Grafana CLI
grafana-cli dashboards import monitoring/grafana/dashboards/overview.json
grafana-cli dashboards import monitoring/grafana/dashboards/threats.json
grafana-cli dashboards import monitoring/grafana/dashboards/ai-gateway.json
# Or via API
curl -X POST http://grafana:3000/api/dashboards/import \
-H "Authorization: Basic admin:admin" \
-H "Content-Type: application/json" \
-d @monitoring/grafana/dashboards/overview.jsonAlert Rules
| Alert | Severity | Condition | Default threshold |
|---|---|---|---|
| GatewayDown | critical | g8kepr_gateway_health == 0 | Immediate |
| HighThreatRate | warning | rate(g8kepr_threats_total[5m]) > N | > 50/min |
| HighLatency | warning | p95 request duration | > 2s for 5 min |
| ContainerRestarting | critical | restart count delta | > 3 in 15 min |
| RedisLatencyHigh | warning | g8kepr_redis_latency_seconds p99 | > 100ms |
| TokenBudgetNearing | warning | daily token spend vs limit | > 80% of budget |
Log Format
All logs are structured JSON, written to stdout. Each log line includes request_id for end-to-end tracing.
{
"level": "info",
"time": "2026-03-31T14:22:01.432Z",
"request_id": "req_xyz789",
"org_id": "org_abc123",
"gateway_id": "gw_prod_01",
"method": "POST",
"path": "/v1/completions",
"status": 403,
"duration_ms": 4,
"threat_score": 0.91,
"decision": "block",
"pattern": "PI-001"
}Changelog
Recent, customer-facing improvements to the G8KEPR platform. Feature-level only — contact support for detailed release notes.
- NewAgent hijacking detection across multi-agent pipelines — context poisoning, agent impersonation, exfiltration-via-agent, prompt chaining, and sleeper payloads
- NewMCP Security: multi-turn session tracking, tool-level RBAC, and explainable threat scoring
- NewAI Gateway: multi-provider routing (round-robin, least-latency, cost-optimized, failover) with bring-your-own-key providers
- NewWebhooks for threat.blocked, gateway.down, and rate_limit.exceeded, with automatic retry and circuit-breaking
- NewHIPAA evidence tooling scoped per organization for accounts with a signed BAA
- NewPrometheus metrics and pre-built Grafana dashboards for requests, threats, and AI Gateway spend
Start protecting your APIs today
The free Community plan includes 100K findings per month and full threat detection. Every new account starts with a 30-day Starter trial (extend to 90 days free) — no credit card required.