REST API context gathering
Use therest-api context-gathering strategy when your agent needs live data from your own APIs before it executes, such as user profiles, CRM records, entitlement state, or billing status. Velt fetches the configured endpoints at execution time and injects the collected results into the prompt with the {{restApiData}} template variable.
strategyOptions["rest-api"]
| Field | Type | Required | Notes |
|---|---|---|---|
endpoints | RestApiEndpoint[] | yes | 1–10 endpoints. |
maxResponseBytes | number | no | Per-endpoint cap. Default 1000000, max 5000000. |
RestApiEndpoint
| Field | Type | Required | Notes |
|---|---|---|---|
url | string | yes | SSRF-validated URL. Supports {{variable}} templating. |
description | string | yes | Surfaced in the prompt alongside the URL and response. |
method | "GET" / "POST" / "PUT" / "PATCH" / "DELETE" | no | Default "GET". |
auth | RestApiAuthConfig | no | none, bearer, basic, or header. Secret fields are encrypted at rest and redacted on read. |
headers | Record<string, string> | no | Request headers. Supports templating. |
query | Record<string, string> | no | Query parameters. Supports templating. |
body | unknown | no | Request body. Supports templating. |
cacheTtlSeconds | number | no | In-process cache TTL per Cloud Function instance. Default 0, max 86400. |
timeoutMs | number | no | Per-request timeout. Default 10000, max 30000. |
responsePath | string | no | Dot-path to extract a sub-field of the JSON response. |
url, headers, query, and body with {{variable}}, {{userContext.X}}, and {{variables.X}}. Endpoint URLs are SSRF-guarded and block internal, loopback, and link-local hosts. Secret auth fields are encrypted at rest and redacted on every read path.
MCP tool execution
Useexecution.executionStrategy: "mcp-tools" when the agent needs a multi-turn tool loop. The agent connects to one or more customer-configured MCP servers over remote HTTP / Streamable HTTP transport, sends only the allowed tool schemas to the model, executes model-requested tools, and returns a structured response.
AI_TOOLS_NOT_SUPPORTED.
Built-in docs code comparison agent
The built-indocs-code-comparison agent verifies code snippets on a landing page against your docs site and reports mismatches as annotations. It uses web-page-text context gathering with includeCodeBlocks: true and the mcp-tools execution strategy against a remote docs MCP server. It works with Claude and Gemini.
Configuration safety
Partial custom-agent config updates deep-merge nested objects, so updating one field underexecution or contextGathering preserves sibling fields such as execution.mcpServers.
Create and update-version payloads reject server-managed keys with 400 INVALID_ARGUMENT:
managedBymetadata.typemetadata.categorymetadata.internalmetadata.apiKey
ai, service+ai, and stagehand-agent) reject create and update payloads with 400 INVALID_ARGUMENT when instructions is missing or empty.
