Skip to main content
Purchases a prepaid credit pack for a specific agent. After purchase, future runs of that agent consume pack units instead of creating a new payment — until the pack is exhausted or expires. Packs offer a per-run discount vs. the PAYG price. See list_agent_credit_packs for available offers before buying.

Parameters

NameTypeRequiredDescription
agent_idstringyesAgent UUID or slug
pack_idstringnoSpecific pack ID (omit if the agent offers only one)
pay_withstringnoRail: tempo, base, solana, or a wallet ID
confirmedbooleannoSet true on the second call to confirm the quote

Example

buy_agent_credit_pack({
  agent_id: "company-enrichment",
  pay_with: "base",
  confirmed: true
})