# Aegis Spend Guard

Owner-set spend policy for Ulpi, enforced in a pre_tool_call hook before any spend executes.

- Type: Plugin
- Version: 1.1.2
- Updated: 22 Nov 2026
- Publisher: georgeonweb3
- Category: Tools

[Contact us](https://www.ulpi.io/en/support#contact)

## What it does

Owner-set spend policy for Ulpi, enforced in a pre_tool_call hook before any spend executes. The owner configures a per-transaction cap, a daily limit, recipient allow/blocklists, a spend-tool scope and a warn zone (default 80% of a limit).

Every tool call that spends money — an explicit amount in its arguments, a fixed per-call price from the owner's paid_tools map, a spend-shaped tool with no readable price, or a spend written into command/script text the agent is about to run (a money literal alongside a payment verb; on by default, the owner can turn the script gate off) — is evaluated by a worst-wins policy engine (BLOCK \> WARN \> ALLOW across frozen, amount, blocklist, per-transaction cap, daily limit, allowlist and tool-scope checks, the same semantics as the author's Aegis spend-control contract on Base and the tgp-guard pre-flight guard). Over-policy spends are vetoed with the reason; borderline spends return the approve directive and are routed to the owner through Ulpi's own human-approval gate — the plugin never approves anything itself.

Executed spends are recorded in a per-profile daily ledger held in ctx.state, and a /spendguard slash command gives the owner status plus a persistent freeze/unfreeze kill switch. Two tools (spend_guard_check, spend_guard_status) let the agent dry-run a planned spend and report guard state.

Disclosure — no Python dependencies, no network calls, no shell commands, no credentials read or stored, no telemetry; the only writes are the plugin's own ctx.state keys (freeze flag, daily total). Known limit, disclosed in the README: parallel spend calls are each checked against the ledger as it stands before either executes, so a simultaneous burst can overshoot the daily limit by one call.

## Tools it adds

The tools an agent gets once this plugin is installed.

- `spend_guard_check`
- `spend_guard_status`

## Review notes

What an owner reads and accepts before the install is approved.

- Ulpi has not reviewed this version: it is listed in the public plugin catalog, and the install still fetches it at its pinned commit, checks its shape and scans it before you approve

## More in Tools

- [Affiliateo](https://www.ulpi.io/en/marketplace/plugins/affiliateo): The key is a config_schema secret (AFFILIATEO_API_KEY) kept by Ulpi and sent only as the Authorization header to affiliateo.com.
- [AfriRadar](https://www.ulpi.io/en/marketplace/plugins/afriradar): Nigerian and Kenyan fund data from the regulators (SEC Nigeria weekly, CMA Kenya quarterly): rank, compare and project funds, keep a watchlist.
- [Aftercare](https://www.ulpi.io/en/marketplace/plugins/aftercare): Your agent checks its own work after the fact.

[All listings →](https://www.ulpi.io/en/marketplace) · [Publisher's guide →](https://www.ulpi.io/en/docs) · [Report a problem →](https://www.ulpi.io/en/security#report)
