---
title: "One-click wallet top-up purchase"
method: POST
path: "/credits/topup"
tags: ["credits"]
---

# One-click wallet top-up purchase

`POST /credits/topup`

## Request

- Base URL: `https://api.autron.ai`
- URL: `https://api.autron.ai/credits/topup`
- Auth: API key in header `Authorization`

The agent app sends a wallet pack key (server-authoritative
pricing — see ``pricing_catalog.WALLET_PACKS_SEMANTIC``) and a
client-generated ``request_id`` (uuid per click). Retries with
the same ``request_id`` can never double-charge (Stripe
idempotency key) or double-grant (unique partial index on the
PaymentIntent id).

Status → HTTP: ``payment_required`` → 402 (agent app routes to
the Billing Portal, same as pack changes), ``not_subscriber`` →
403, ``fail`` → 400, ``success`` → 200.

## Request body

- object
  - `pack_key` string
  - `request_id` string

## Response `200`

Success

---

[API](https://skmtc.dev/autron/apis/autron-api.md) · [All operations](https://skmtc.dev/autron/apis/autron-api/llms.txt) · [OpenAPI document](https://skmtc.dev/autron/apis/autron-api/revisions/f696bfa7295f?raw)
