Skip to main content
POST
/
wallets
/
{id}
/
debit
Debit a wallet
curl --request POST \
  --url https://api.alguna.io/wallets/{id}/debit \
  --header 'Alguna-Version: <alguna-version>' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "amount": "<string>",
  "reference_id": "pay_01H3DEF",
  "transaction_type": "payment",
  "description": "<string>"
}
'
{
  "active": true,
  "created_at": "2026-04-01T10:00:00Z",
  "currency": "USD",
  "current_balance": "<string>",
  "customer_id": "cust_01H2ABC",
  "id": "wlt_01H1VECT",
  "name": "Main Wallet",
  "updated_at": "2026-04-01T12:30:00Z",
  "product_ids": [
    "<string>"
  ]
}

Documentation Index

Fetch the complete documentation index at: https://alguna.com/docs/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

API key authentication. Pass your API key as a Bearer token.

Headers

Alguna-Version
enum<string>
required
Available options:
2026-04-01
Idempotency-Key
string

A unique string used to ensure the request is processed exactly once. If you retry a request with the same idempotency key within 24 hours, the original response is returned without re-executing the operation.

Maximum string length: 255
Example:

"ik_a1b2c3d4e5f6"

Path Parameters

id
string
required

Unique identifier for the wallet

Body

application/json
amount
string
required

Amount to credit or debit

reference_id
string
required

Reference identifier for the transaction

Example:

"pay_01H3DEF"

transaction_type
enum<string>
required

Type of transaction

Available options:
credit_grant,
payment,
refund,
manual_debit
Example:

"payment"

description
string | null

Description of the transaction

Response

Success

active
boolean
required

Whether the wallet is active

Example:

true

created_at
string<date-time>
required

Timestamp when the wallet was created

Example:

"2026-04-01T10:00:00Z"

currency
string
required

Currency code

Example:

"USD"

current_balance
string
required

Current balance of the wallet

customer_id
string
required

Identifier of the customer that owns this wallet

Example:

"cust_01H2ABC"

id
string
required

Unique identifier for the wallet

Example:

"wlt_01H1VECT"

name
string
required

Name of the wallet

Example:

"Main Wallet"

updated_at
string<date-time>
required

Timestamp when the wallet was last updated

Example:

"2026-04-01T12:30:00Z"

product_ids
string[]

Product IDs that can be purchased with this wallet