pub struct RouteEntry {
pub tool: Option<StringOrList>,
pub resource: Option<StringOrList>,
pub prompt: Option<StringOrList>,
pub llm: Option<StringOrList>,
pub meta: Option<RouteMeta>,
pub when: Option<String>,
pub plugins: Vec<PluginRouteRef>,
pub identity: Option<RouteIdentityConfig>,
}Expand description
A per-entity routing rule.
Matches one entity type (tool, resource, prompt, or LLM) and determines which plugins fire.
Fields§
§tool: Option<StringOrList>Match a tool by exact name, list, or glob.
resource: Option<StringOrList>Match a resource by exact URI, list, or glob.
prompt: Option<StringOrList>Match a prompt by exact name, list, or glob.
llm: Option<StringOrList>Match an LLM by exact model name, list, or glob.
meta: Option<RouteMeta>Operational metadata — tags, scope, properties.
when: Option<String>Conditional match expression — carried but not evaluated during static resolution. Evaluated at runtime when payload data is available (future: APL evaluator).
plugins: Vec<PluginRouteRef>Plugin references to activate for this route.
identity: Option<RouteIdentityConfig>Authentication dispatch list for this route (YAML key
authentication:). Hook-specific: applies ONLY to the
identity.resolve hook, independent of the plugins: block above
(which is hook-agnostic and means different things depending on
whether APL is annotating the route — authentication: always
means “these plugins fire on identity.resolve in this order”).
Accepts two YAML shapes; both deserialize to the same IR.
See crate::identity::route_config::RouteIdentityConfig.
# List form — common case, additive default
authentication:
- corp-jwt
- spiffe-attestor
# Object form — when the override flag is needed
authentication:
replace_inherited: true
steps:
- legacy-basic-authTrait Implementations§
Source§impl Clone for RouteEntry
impl Clone for RouteEntry
Source§fn clone(&self) -> RouteEntry
fn clone(&self) -> RouteEntry
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more