Skip to content

AI drafts. People pay.

The most capable part of SettleShort, the model, has the least authority. This is everything that stands between a receipt and a payout.

The Approve & Pay confirmation dialog, asking the admin to type APPROVE before paying 3 people $287.55.
Human approval gate
AI never starts a payout. A batch reaches PayPal only after an admin clicks Approve & Pay and types APPROVE. Per-payout and per-batch caps limit the damage of any approved mistake.
Sandbox only
The PayPal client is pinned to the sandbox API. A live endpoint is refused in code, not just in config. Without sandbox credentials, a clearly labelled payout simulator runs instead.
Least privilege
Members submit and edit their own claims. Only admins build batches and approve payouts. Roles are checked on the server for every request, never trusted from the client.
Audit everything
Claim creation, AI extraction (including the raw model output), edits, merges, rejections, approvals and every PayPal webhook are logged with actor and timestamp.
Prompt-injection mitigation
Model output must match a strict JSON schema and is validated again with Zod before it touches the database. Receipt and message text is data only. It can fill fields, never trigger actions.
Idempotency
Each batch carries its own sender_batch_id, and PayPal rejects a reused one, so retries and double clicks cannot pay anyone twice. Webhook status updates are safe to replay.
Workspace scoping
Every query is scoped to the caller’s workspace. Claims, payees, batches and uploads from one workspace are never readable from another.
Secrets stay on the server
PayPal, Anthropic, OpenAI, session and webhook secrets live in server-only environment variables. Inbound webhooks need a shared secret or PayPal signature verification.

Found an issue? Open a report on GitHub.