Stripe Voice

@tuttiai/stripe — broad coverage of the Stripe API, with HITL gates on every write

The Stripe voice gives agents broad access to the Stripe API: customers, products, prices, payment links, payment intents, charges, refunds, subscriptions, invoices, disputes, and balance.

Every write tool is marked destructive: true, so HITL-enabled runtimes pause for human approval before any state change. This matters here: a create_refund, cancel_subscription, or void_invoice against an sk_live_ key moves real money.

Installation

npx tutti-ai add stripe

Required permissions

permissions: ["network"]

Required environment variables

VarDescription
STRIPE_SECRET_KEYStripe secret key — strongly prefer sk_test_... while developing

Add to your .env:

STRIPE_SECRET_KEY=sk_test_...

The voice detects the sk_live_ prefix and stamps [test] on every output line for test-mode keys; rely on that visual cue while reviewing.

For least-privilege production deployments, create a restricted key granting only the resources the agent needs (e.g. read on customers/charges/invoices, write on refunds).

Configuration

// Default: reads STRIPE_SECRET_KEY from env
new StripeVoice()

// Explicit key
new StripeVoice({ api_key: "sk_test_..." })

Tool reference (27 tools)

Customers (3)

ToolDestructiveDescription
list_customersnoList customers, filter by email, paginate.
get_customernoOne customer by id.
create_customeryesCreate a new customer.

Products & Prices (4)

ToolDestructiveDescription
list_productsnoList products, filter by active flag.
create_productyesNew product.
list_pricesnoList prices, filter by product/active.
create_priceyesNew price (one-time or recurring) for a product.
ToolDestructiveDescription
create_payment_linkyesShareable checkout link for one or more prices.

Payments (5)

ToolDestructiveDescription
list_payment_intentsnoList intents, filter by customer.
get_payment_intentnoOne intent with status, amounts, last error.
cancel_payment_intentyesCancel an uncaptured intent.
list_chargesnoList charges, filter by customer/payment_intent.
get_chargenoOne charge with capture/refund details.

Refunds (3)

ToolDestructiveDescription
list_refundsnoList refunds, filter by charge/payment_intent.
get_refundnoOne refund.
create_refundyesRefund a charge or intent — moves money back to the customer.

Subscriptions (3)

ToolDestructiveDescription
list_subscriptionsnoList subs, filter by customer/status.
get_subscriptionnoOne sub with period + line items.
cancel_subscriptionyesImmediate cancel (with optional invoice_now / prorate).

Invoices (4)

ToolDestructiveDescription
list_invoicesnoList invoices, filter by customer/status.
get_invoicenoOne invoice.
finalize_invoiceyesFinalize a draft invoice.
void_invoiceyesVoid a finalized invoice.

Disputes (2)

ToolDestructiveDescription
list_disputesnoList disputes, filter by charge.
get_disputenoOne dispute with evidence + due date.

Balance (2)

ToolDestructiveDescription
get_balancenoAvailable + pending balances per currency.
list_balance_transactionsnoRecent balance transactions.

Example

import { defineScore, AnthropicProvider } from "@tuttiai/core";
import { StripeVoice } from "@tuttiai/stripe";

export default defineScore({
  provider: new AnthropicProvider(),
  agents: {
    support: {
      name: "support",
      model: "claude-sonnet-4-20250514",
      system_prompt:
        "You handle billing-related support tickets. Look up customers, summarise charges and subscriptions, and propose refunds — never execute a refund without explicit human approval.",
      voices: [new StripeVoice()],
      permissions: ["network"],
    },
  },
});

Run it:

tutti-ai run support "Customer alice@acme.com is asking why their last invoice was higher than usual"

With a HITL-enabled runtime, every write call (refund, cancel, void, create) pauses for human approval before execution.

Edit this page on GitHub →