Component ยท Control side
Trait api-configuration
BOTH Concept Control plane
What it is
The api-configuration trait is an OpenChoreo add-on attached to each agent. It changes the agent's HTTPRoute so incoming traffic is sent to the API Platform Gateway first, and it applies the gateway policies for that agent.
Why it exists
Without it, requests would reach the agent directly, skipping authentication, CORS and other policies that the gateway enforces.
How it works
- Patches the agent HTTPRoute so its backend is the API Platform Gateway with weight 100.
- Creates or updates the agent's RestApi so the gateway knows the policy chain to run.
- Is one of the traits allowed by the agent-api ComponentType.
- AMS attaches it when the agent is created.
Identity and access
It is what puts authentication in front of the agent. The gateway route it sets up requires exactly one of api-key-auth or jwt-auth for invocation.
Key facts
- Trait name
- api-configuration
- Backend weight
- 100
- Side
- Control plane (applies to data plane)
- Namespace
- default ns
Talks to (1)
- calls API Platform Gateway runtime (APG) Routes agent traffic through APGHTTPRoute backend weight 100
Used by (1)
- needed by ComponentType agent-api Allowed traitallowedTraits