TL;DR: Enterprises often have 40% to 60% more APIs than gateway inventories show, because internal service calls, sampled telemetry, Kubernetes ephemerality, and AI-generated runtime connections create structurally hidden traffic, according to AccuKnox. The result is a visibility problem that conventional gateways and static scanning cannot solve; kernel-level discovery becomes the decisive control boundary.
At a glance
What this is: This is a practical analysis of why API security tools miss large parts of the runtime surface, especially shadow APIs, east-west traffic, drift, and LLM-driven connections.
Why it matters: For IAM and security teams, the gap matters because unseen API paths can hide privileged access, service-account abuse, and machine-to-machine trust relationships that governance programmes cannot review or control.
By the numbers:
- Most enterprises discover they have 40-60% more APIs than their gateway configurations show.
- A 5% sample means 95% of API calls are unobserved.
👉 Read AccuKnox's full guide on API visibility gaps and runtime discovery
Context
API visibility is not just a tooling issue. It is a governance problem created by architectures that move traffic outside the controls security teams usually inspect, including gateways, static inventories, and sampled monitoring. In API-heavy environments, the primary risk is not only exposed endpoints, but unmanaged runtime connections that security teams never see in the first place.
That gap becomes more consequential when APIs are used by microservices, Kubernetes workloads, and AI systems. In those environments, access often depends on service identities, tokens, and delegated runtime calls, which means visibility failures quickly become identity and privilege failures as well. AccuKnox frames the issue as a structural blind spot, and that is a fair reading of most modern API estates.
Key questions
Q: What breaks when API security depends only on gateways and WAFs?
A: Teams lose visibility into business logic abuse, object-level authorisation failures, and low-and-slow reconnaissance that looks legitimate at the transaction layer. Gateways and WAFs still have value, but they cannot reliably judge intent, object ownership, or whether a valid session is being used outside its intended scope. That leaves a major gap in runtime control.
Q: When should teams prioritise runtime API discovery over static scanning?
A: Prioritise runtime discovery when systems change after deployment, when microservices communicate laterally, or when AI workloads create API calls dynamically. Static scanning is still useful for baseline inventory, but it cannot prove what is live now. If the operational question is what is actually being called, runtime evidence should lead the decision.
Q: What do security teams get wrong about sampled API monitoring?
A: They often assume a sample can represent a live API estate accurately. In practice, low-frequency, high-value calls are exactly the ones sampling is most likely to miss. That makes sampled monitoring useful for trend analysis, but weak for control validation, incident response, and privileged access governance.
Q: How can organisations govern AI-generated API code safely?
A: They should apply the same controls to agent-authored code as to human-written code, with no exceptions. That means policy checks on every commit, automated secrets scanning, dependency scanning, and review of generated authentication logic. If AI can create endpoints and scopes faster than humans can inspect them, governance has to become machine-enforced.
Technical breakdown
Why gateways miss east-west API traffic
API gateways only observe traffic that is explicitly routed through them. Internal service-to-service calls, pod-to-pod communication, and sidecar traffic often bypass that choke point entirely, which means the gateway inventory is not a runtime inventory. In cloud-native systems, this creates a persistent mismatch between what is managed and what is actually executed. The core issue is architectural scope, not operator error. If the control only sits at the edge, anything that moves laterally inside the environment remains outside policy inspection and most logging pipelines.
Practical implication: treat gateway inventories as incomplete and test whether internal traffic paths are visible before trusting any API control model.
How sampling and static scanning create drift gaps
Sampled telemetry and code or spec scanning both describe a partial view. Sampling misses low-frequency calls by design, while static analysis freezes the API surface at deployment and cannot see post-release changes, new parameters, or altered authentication rules. That is why drift gaps appear even in environments with mature CI/CD controls. The security problem is not that these tools are broken; it is that they operate at different times and with different assumptions than runtime behaviour. If the live system changes after deployment, the inventory must change with it.
Practical implication: require continuous runtime comparison against the deployed baseline, not just build-time validation or sampled observation.
Why LLM API connection mapping is becoming a governance issue
AI applications now generate outbound calls at inference time to model endpoints, vector databases, tool-use APIs, and MCP servers. Those connections are determined by runtime context, not by static code paths, so traditional discovery methods cannot reliably enumerate them. This is where API visibility becomes identity governance: each call is initiated by a workload identity, service account, or agent context that must be attributable. Without that linkage, least privilege for AI workloads is impossible to prove and difficult to enforce.
Practical implication: tie every AI-generated API call to workload identity and runtime context before allowing the call path into production.
Threat narrative
Attacker objective: The attacker wants to use unseen API paths and unmanaged runtime connections to reach sensitive logic, data, or privileged service identities without triggering the controls built around the gateway.
- Entry occurs through shadow APIs, unregistered microservice endpoints, or AI-generated runtime calls that never pass through the gateway layer.
- Escalation follows when sampled telemetry or static inventories miss low-frequency or post-deployment changes, leaving privileged paths and drift unmonitored.
- Impact is exposure of business logic, lateral movement through internal API paths, or unauthorized access to model, data, and service credentials.
NHI Mgmt Group analysis
API visibility has become an identity problem, not just an observability problem. When APIs are invoked by service accounts, workloads, and AI systems, unseen traffic means unseen trust relationships. That shifts the control question from 'what endpoints exist?' to 'which identities are allowed to reach them, and how are those paths governed?' Practitioners should align API discovery with identity and privilege review, not treat it as a separate inventory exercise.
Kernel-level discovery changes the category because it changes the evidence base. Gateway records, sampled logs, and spec scans all answer different questions, but none of them provide deterministic runtime truth across heterogeneous environments. The named concept here is runtime surface drift: the gap between declared APIs and the live paths actually used in production. Teams should evaluate tooling on whether it can close that drift continuously, not just detect it after the fact.
LLM API connection gaps are the next governance blind spot. AI systems can create outbound connections that no design-time review captured, especially when tool use is selected dynamically at inference time. That makes workload identity, service-account attribution, and policy enforcement inseparable from API visibility. Practitioners should expect API governance to converge with NHI governance wherever AI agents or model pipelines initiate calls on their own.
Continuous runtime visibility will force security teams to re-baseline compliance evidence. If the live API surface is changing independently of the gateway catalogue, then audit artefacts based on static inventories will understate exposure. This is especially relevant where service identities are reused across namespaces or environments. Teams should treat runtime discovery as the authoritative source for both control validation and remediation prioritisation.
What this signals
API visibility programmes are starting to converge with identity governance because every hidden API path usually has an owner, a workload identity, or a secret behind it. For practitioners, that means the next maturity step is not just better dashboards, but a control model that reconciles runtime discovery with entitlement review and service-account accountability.
Runtime surface drift: the fastest way to lose control of APIs is to maintain a static inventory in a dynamic system. If your tool cannot detect post-deployment changes, then your policy, compliance, and incident evidence will all age faster than the environment itself.
The practical lesson for security teams is to benchmark API discovery by what it sees in production, not by what it claims in a lab. Where AI systems are generating tool calls, the governance boundary now includes the initiating workload identity, the destination service, and the revocation path for the credential in between.
For practitioners
- Map the live runtime API surface Run a 72-hour runtime discovery exercise across production paths, then compare the result to gateway registrations and spec inventories to quantify the visibility gap.
- Separate unmanaged endpoints from drifted endpoints Classify uncovered APIs into shadow, zombie, and drift categories so remediation can target registration, retirement, or runtime policy correction instead of generic cleanup.
- Require identity attribution for AI-originated calls Tie every model, vector, and MCP call to the initiating workload identity or service account so AI-generated traffic can be governed as a privileged access path.
- Test tools for zero-sampling coverage Validate whether a platform can prove 100% capture across east-west traffic, pod traffic, and post-deployment changes before relying on it for security decisions.
- Rebaseline API governance around runtime truth Use runtime-discovered inventories as the source of record for policy, compliance evidence, and privilege review, then reconcile gateways against that baseline regularly.
Key takeaways
- The central risk is not only exposed APIs, but the gap between declared inventory and live runtime traffic.
- Sampling, static scanning, and gateway controls each leave structural blind spots that matter most in microservices, Kubernetes, and AI workflows.
- Practitioners should rebase API governance on runtime evidence and identity attribution before treating visibility as complete.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
MITRE ATT&CK address the attack and risk surface, while NIST CSF 2.0, NIST SP 800-53 Rev 5, CIS Controls v8 and NIST Zero Trust (SP 800-207) set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| MITRE ATT&CK | TA0007 , Discovery; TA0008 , Lateral Movement; TA0011 , Command and Control | The article focuses on hidden API paths that enable discovery and lateral movement. |
| NIST CSF 2.0 | DE.CM-1 | Continuous monitoring is central to detecting runtime API drift and shadow traffic. |
| NIST SP 800-53 Rev 5 | AU-2 | Runtime API visibility depends on auditable records of service and workload interactions. |
| CIS Controls v8 | CIS-8 , Audit Log Management | The guide hinges on complete runtime telemetry for API paths and workload activity. |
| NIST Zero Trust (SP 800-207) | Zero Trust assumes continuous verification of every connection, including internal API calls. |
Use zero-trust principles to verify each API call independently instead of trusting network location or gateway presence.
Key terms
- Shadow API: An API endpoint that exists in production but is not fully known, reviewed, or governed by the security programme. Shadow APIs often emerge through fast delivery, copy-paste development, or overlooked internal routes, and they create untracked exposure because they sit outside inventory, policy, and ownership processes.
- Runtime Tool Surface Drift: A change in the effective privilege boundary that happens while an agent is executing, usually because it leaves the primary tool path and starts composing with broader commands or fallback tools. It is a governance issue because the controlled path no longer matches the actual path.
- East-west traffic: East-west traffic is communication that moves between systems inside an environment rather than entering or leaving it. In microsegmentation programmes, it is the traffic most likely to expose hidden trust assumptions and is therefore the main target for workload-level policy.
- LLM API Connection Gap: A visibility gap created when AI systems generate outbound calls at inference time to model endpoints, tools, vector databases, or MCP servers. Because these calls are selected dynamically, they can evade static discovery and complicate least-privilege governance for AI workloads.
What's in the full article
AccuKnox's full guide covers the operational detail this post intentionally leaves for the source:
- The five-point API visibility assessment framework you can use to score tools before purchase.
- The runtime discovery workflow for comparing gateway counts against live production traffic.
- The detailed breakdown of kernel-level eBPF coverage across external and east-west API paths.
- The AI API connection mapping section that shows how model, vector, and MCP calls are surfaced in context.
Deepen your knowledge
The NHI Foundation Level course, the industry's only accredited NHI security programme, covers NHI governance, machine identity security, and secrets management. It helps practitioners connect identity controls to the broader access problems exposed by modern runtime architectures.
Published by the NHIMG editorial team on August 21, 2026.
NHI Mgmt Group — the independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org