vault_call
Calls web services using vault-stored secrets without exposing credentials: the broker attaches the secret, sends the request, and returns the response with the secret removed.
Instructions
Call a web service with a vaulted secret that is never returned to you: the broker attaches the secret, sends the request and gives you the answer with the secret removed.
Two ways to call. Describe the request yourself with request (origin, method, path, and optional query, body and your own headers). Or run a named operation the owner defined, with operation_id and typed args: the operation fixes the origin and route, returns only the fields it permits, and is signed with a key derived from the secret itself, so a definition altered in transit is refused. vault_entries_list shows which operations an entry offers.
Either way the entry decides how the secret is attached (a header, a query parameter, a username and password, or part of the web address) — you never choose that, and never see the secret.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | No | Typed arguments for operation_id, checked against its schema. | |
| purpose | Yes | Why this is needed (audit log). | |
| request | No | Describe the call yourself: {origin:{scheme,host,port}, method, path, body?, query?, headers?}. body: an object or array is sent as JSON; a string is sent as written (set content-type in headers, e.g. application/x-www-form-urlencoded). headers: your own, such as user-agent or an API version; the header that carries the secret, and framing headers, are refused. If the entry keeps its secret in the web address (Telegram, webhooks), path is only what comes AFTER the secret, e.g. /sendMessage, or / for the stored address as is. Tier 1 secrets proceed and are logged. Tier 2 secrets are refused until the owner approves this exact origin, method and path; the approval covers whatever headers and body it carries. STAMPED keys (AWS, X, SnapTrade, exchanges) never travel: add request.stamp describing how the service signs requests, either {builtin:"aws-sigv4", region, service}, {builtin:"oauth1"} for OAuth 1.0a (X, Tumblr, Flickr; optional signature_method:"HMAC-SHA256" and realm for NetSuite; nonce, timestamp and the Authorization header are written for you; the owner stores the four values as {"api_key","api_secret","access_token","access_token_secret"}), or {mac:"hmac-sha256"|"hmac-sha384"|"hmac-sha512", key:"utf8"|"base64"|"hex", message:[parts], encoding:"hex"|"base64"|"base64url", place:[{in:"header"|"query", name, value:"…{stamp}…"}]}. Parts: {text}, {var: method|path|query|path_and_query|body|host|key_id|body_json}, {header: name}, {body_field: name}, {sha256:[parts]}, {sha512:[parts]}, {sha256_hex:[parts]}, {json:{name: part}} (sorted keys, no spaces). Parts read the request before the stamp is placed; put timestamps and nonces in the request yourself. place values may use {stamp} and {key_id}. The owner approves each recipe once per address; the first call waits for that. | |
| entry_id | Yes | Vault entry holding the credential. | |
| operation_id | No | A signed operation on the entry. Use this OR request, not both. |