Get one wallet transaction
Auth: Authorization: Bearer nsin_… or X-Api-Key: nsin_… — see API keys.
The ledger row, plus — for a traffic charge — the per-domain byte and
cost breakdown of that billing window. A traffic charge is billed once
per account per window, summed across all your domains, so by_domain
is how you attribute it.
Path parameters
- idintegerrequiredpath
Responses
200Transaction detail.
Content type: application/json
- idinteger
- wallet_idinteger
- user_idinteger
- typestring
topup— money added.purchase— a plan bought or renewed.refund.admin_adjust— a correction by NSIN support.traffic_usage— a traffic charge.signup_bonus— the credit granted at signup.One of:"topup""purchase""refund""admin_adjust""traffic_usage""signup_bonus" - amount_rialsinteger
Signed — positive credits, negative debits.
- balance_afterinteger
- descriptionstring
- ref_typestring
What the row refers to —
payment,subscription,trafficormanual. - ref_idinteger
- ref_codestring
Payment gateway reference, for top-ups.
- origin_nodestring
Internal — set on rows replicated from another NSIN region. Clients can ignore it.
- sync_keystring
Internal — the replication idempotency key of a replicated row. Clients can ignore it.
- created_atstring (date-time)
- domain_idinteger
The domain a traffic charge is attributed to. Only on rows of
GET /wallet/transactions. - domain_namestring
That domain's name. Only on rows of
GET /wallet/transactions. - nodestring
- billing_window_keystring
Identifies the billing window a traffic charge covers.
- by_domainarray of TrafficDomainBreakdown
Per-domain contribution to this charge. Traffic charges only.
Item fields
- domain_idinteger
- domain_namestring
- cached_bytesinteger
- proxied_bytesinteger
- direct_bytesinteger
- bypass_bytesinteger
Legacy two-tier column, on historical rows only.
- charged_rialsinteger
- cached_bytesinteger
Total across
by_domain. - proxied_bytesinteger
Total across
by_domain. - direct_bytesinteger
Total across
by_domain. - bypass_bytesinteger
Total across
by_domain. - charged_rialsinteger
Total charged across
by_domain.
{
"id": 0,
"wallet_id": 0,
"user_id": 0,
"type": "topup",
"amount_rials": 0,
"balance_after": 0,
"description": "string",
"ref_type": "string",
"ref_id": 0,
"ref_code": "string",
"origin_node": "string",
"sync_key": "string",
"created_at": "2026-01-01T00:00:00Z",
"domain_id": 0,
"domain_name": "string",
"node": "string",
"billing_window_key": "string",
"by_domain": [
{
"domain_id": 0,
"domain_name": "string",
"cached_bytes": 0,
"proxied_bytes": 0,
"direct_bytes": 0,
"bypass_bytes": 0,
"charged_rials": 0
}
],
"cached_bytes": 0,
"proxied_bytes": 0,
"direct_bytes": 0,
"bypass_bytes": 0,
"charged_rials": 0
}401Missing, malformed, revoked or expired API key. (A valid key whose
account has been deactivated gets 403 account is inactive instead.)
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "invalid API key"
}404No such transaction on this account.
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "read-only API key"
}429The key exceeded its request budget (300 requests per minute by default).
Content type: application/json
- errorstringrequired
Human-readable description of what went wrong.
{
"error": "rate limit exceeded"
}Example request
curl -X GET "https://api.nsin.ir/wallet/transactions/0" \
-H "Authorization: Bearer $NSIN_API_KEY"