Tài liệu / API Reference/ Danh sách tài khoản

Danh sách tài khoản

API Reference Cập nhật: 23/03/2026

Tài khoản ngân hàng

Danh sách tài khoản

GET /api/v1/bank-accounts
Authorization: Bearer YOUR_API_KEY

Response

{
  "status": true,
  "messages": "Thành công",
  "bank_accounts": [
    {
      "id": 2,
      "bank": "ACB",
      "account_number": "7465441",
      "account_name": "TRUNG DANG LE",
      "status": "active",
      "created_at": "2026-03-22 07:55:23"
    }
  ]
}

Mô tả trường

TrườngKiểuMô tả
idintegerID tài khoản
bankstringMã ngân hàng (ACB, VCB, BIDV, MBB, CTG)
account_numberstringSố tài khoản
account_namestringTên chủ tài khoản
statusstringactive, inactive, pending, error
created_atstringNgày liên kết

Thống kê tài khoản

GET /api/v1/bank-accounts/summary
Authorization: Bearer YOUR_API_KEY

Trả về thống kê giao dịch chi tiết theo ngày, tuần, tháng cho từng tài khoản.

Response

{
  "status": true,
  "messages": "Thành công",
  "banks": [
    {
      "id": 2,
      "account_number": "7465441",
      "bank": "ACB",
      "account_name": "TRUNG DANG LE",
      "status": "active",
      "transaction_count": 35,
      "total_amount": 4766800,
      "today_transaction_count": 5,
      "today_total_amount": 342000,
      "week_transaction_count": 35,
      "week_total_amount": 4766800,
      "month_transaction_count": 35,
      "month_total_amount": 4766800
    }
  ]
}

Mô tả trường

TrườngKiểuMô tả
transaction_countintegerTổng số giao dịch
total_amountintegerTổng số tiền (VND)
today_transaction_countintegerGiao dịch hôm nay
today_total_amountintegerSố tiền hôm nay
week_transaction_countintegerGiao dịch tuần này
week_total_amountintegerSố tiền tuần này
month_transaction_countintegerGiao dịch tháng này
month_total_amountintegerSố tiền tháng này

Bật/Tắt tài khoản

PATCH /api/v1/bank-accounts/{id}/toggle
Authorization: Bearer YOUR_API_KEY

Response

{
  "status": true,
  "messages": "Đã kích hoạt",
  "bank_account": {
    "id": 2,
    "bank": "ACB",
    "account_number": "7465441",
    "account_name": "TRUNG DANG LE",
    "status": "active",
    "created_at": "2026-03-22 07:55:23"
  }
}

Ví dụ cURL

# Danh sách tài khoản
curl -s "https://thueapi.vn/api/v1/bank-accounts" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Thống kê
curl -s "https://thueapi.vn/api/v1/bank-accounts/summary" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Bật/tắt
curl -sX PATCH "https://thueapi.vn/api/v1/bank-accounts/2/toggle" \
  -H "Authorization: Bearer YOUR_API_KEY"
ThueAPI.VN
Đăng nhập với Google
hoặc đăng nhập bằng email
Quên mật khẩu?

Chưa có tài khoản?

Đăng ký với Google
hoặc đăng ký bằng email

Bằng cách đăng ký, bạn đồng ý với Điều khoản dịch vụChính sách bảo mật của chúng tôi.

Đã có tài khoản?