Service is a per-vault configuration that defines which hosts agents can reach through the proxy and how Agent Vault authenticates to each one. When an agent makes a proxied request, Agent Vault matches the target host against the vault’s services, attaches the configured credentials, and forwards the request. If no service matches, Agent Vault returns 403.
Each service contains:
- Host: The target hostname. Supports exact match (e.g.
api.stripe.com) or wildcard patterns (e.g.*.github.com). - Auth config: How Agent Vault authenticates to the host. Five types are supported:
bearer,basic,api-key,custom, andpassthrough(opt out of injection). - Description: An optional human-readable label shown in
/discoverresponses.
- Automatically: As agents do their work, they can raise proposals to add or modify services. You review each proposal, provide any required credentials, and approve. This is the recommended workflow for working with Agent Vault.
- Manually: You can set services directly via the CLI by applying a YAML file or by using the interactive builder. This can be useful for pre-configuring a vault before inviting agents.
Service structure
Services are defined in a YAML file. Here’s what a single service looks like:stripe-services.yaml
host tells Agent Vault which requests this service applies to. The auth block tells Agent Vault how to authenticate, referencing credential keys by name (not the actual credential values). The following section covers all five auth types.
Auth types
Every service must include anauth config that tells Agent Vault how to authenticate to the target host. The auth config references credential key names (not the actual credential values) stored in the vault.
Bearer
Attaches anAuthorization: Bearer <token> header. The token field references a credential key.
Basic
Attaches anAuthorization: Basic <base64> header using HTTP Basic authentication. The username field is required; password is optional (defaults to empty).
API key
Attaches a credential value to a named header with an optional prefix. Theheader field defaults to Authorization if omitted.
Custom
Freeform header templates with{{ SECRET }} placeholders. Each placeholder is resolved to the corresponding credential at proxy time. Use this when none of the typed auth methods fit.
Passthrough
Allowlists the host without injecting a credential. The client’s request headers (includingAuthorization and Cookie) flow through to the target unchanged; Agent Vault strips only hop-by-hop headers and broker-scoped headers (X-Vault, Proxy-Authorization). No credential is stored, read, or attached.
Host matching
Agent Vault supports two host matching modes:- Exact match:
api.stripe.commatches onlyapi.stripe.com. - Wildcard:
*.github.commatchesapi.github.com,uploads.github.com, etc. The*replaces exactly one subdomain segment.
Example
A vault can define multiple services with different auth types:services.yaml
my-vault can now proxy requests to these hosts, and Agent Vault attaches the real credentials at request time.
Managing services
Set from a file
Set interactively
View current services
Clear all services
403 on every proxy request until new services are configured. Prompts for confirmation unless you pass --yes.
How proposals modify services
How proposals modify services
Agents don’t edit service configurations directly. Instead, they propose changes
through proposals, bundles of service and credential
modifications that a human reviews and approves.Each service in a proposal has an
action field:set: Idempotent upsert. Adds the service if the host doesn’t exist, or replaces the existing service for that host. Requireshostandauth.delete: Removes the service matching the given host. Only requireshost.
What happens when an agent hits an unknown host
What happens when an agent hits an unknown host
When a proxy request targets a host not covered by any service, Agent Vault returns
403
with a proposal_hint in the response body. The hint includes the denied
host and the endpoint to create a proposal.Well-behaved agents use this hint to automatically raise a
proposal requesting access. You receive a browser link
to review the request and provide any needed credentials.