Skip to main content

3.3.4 Gửi dữ liệu thanh toán tự động sang MB

REST API

Lưu ý

API này chỉ sử dụng cho đối tác đăng ký sử dụng tính năng thanh toán tự động.

Thông tin chung

  • API Đối tác gửi thông tin trích nợ tự động sang để MB thu theo thông tin đó

Đặc tả

Endpoint

    POST /api/merchant/v2/auto-debit/bills/sync
    Content-Type: application/json
MERCHANT_CODE: Mã đối tác
MERCHANT_SECRET: Khóa bí mật của Đối tác
CLIENT_MESSAGE_ID: Mã tra cứu log giao dịch phía MB(dùng UUID)

Dữ liệu truyền lên

Tham sốMô tả
billPaymentInfo.transactionIdBẮT BUỘC. Kiểu String. Mã giao dịch, Unique message id generated by service consumer for each request (using UUID)
billPaymentInfo.billIdentifiesBẮT BUỘC. Kiểu List. Thông tin bổ sung định danh bill. List phần tử dạng <name;value>
billPaymentInfo.billIdentifies.nameBẮT BUỘC. Kiểu String. Truyền mặc định
"name":"CONTRACT-CODE"
billPaymentInfo.billIdentifies.valueBẮT BUỘC. Kiểu String. Truyền vào mã hợp đồng
billPaymentInfo.billInfosBẮT BUỘC. Kiểu Object. Danh sách các bill
billPaymentInfo.billInfos.amountBẮT BUỘC. Kiểu String. Số tiền thanh toán
billPaymentInfo.billInfos.billIdBẮT BUỘC. Kiểu String. Mã hóa đơn - Truyền vào mã giao dịch autodebit. Ví dụ: AT113WXX1AES
billPaymentInfo.billInfos.billInfoOthersKiểu List. Thông tin bổ sung. Dạng list, mỗi phần tử ở dạng <name;value>. Trường mở rộng, đối tác truyền tùy ý
billPaymentInfo.billInfos.billInfoOthers.nameKiểu String. Thông tin bổ sung. Truyền vào tên biến
billPaymentInfo.billInfos.billInfoOthers.valueKiểu String. Thông tin bổ sung. Truyền vào giá trị
billPaymentInfo.billInfos.descriptionsBẮT BUỘC. Kiểu String. Thông tin bổ sung. Mô tả giao dịch
billPaymentInfo.billInfos.termBẮT BUỘC. Kiểu String. Kỳ thanh toán. Truyền vào kỳ thanh toán
billPaymentInfo.customerInformationBẮT BUỘC. Kiểu Object. Thông tin khách hàng
billPaymentInfo.customerInformation.customerCodeBẮT BUỘC. Kiểu String. Mã khách hàng (mã hợp đồng)
billPaymentInfo.customerInformation.customerAddressKiểu String. Địa chỉ khách hàng
billPaymentInfo.customerInformation.customerNameKiểu String. Tên khách hàng
billPaymentInfo.customerInformation.customerOthersKiểu String. Thông tin khách hàng bổ sung
billPaymentInfo.customerInformation.customerPhoneKiểu String. Số điện thoại KH
billPaymentInfo.partnerBẮT BUỘC. Kiểu String. Truyền mặc định PAYMENT
billPaymentInfo.serviceIdentifiesBẮT BUỘC. Kiểu Object. Bộ thông tin định danh đối tác
billPaymentInfo.serviceIdentifies.serviceCodeBẮT BUỘC. Kiểu String. Mã service thanh toán hóa đơn. Truyền mặc định PAYMENT
billPaymentInfo.serviceIdentifies.providerUnit1CodeBẮT BUỘC. Kiểu String. Mã số 1 định danh đối tác thanh toán. Truyền vào mặc định mã merchant
billPaymentInfo.serviceIdentifies.providerUnit2CodeKiểu String. Mã số 2 định danh đối tác thanh toán
billPaymentInfo.serviceIdentifies.providerUnit3CodeKiểu String. Mã số 3 định danh đối tác thanh toán

Dữ liệu trả về

Tham sốMô tả
transactionlistKiểu List. Danh sách kết quả giao dịch
transactionlist.billIdKiểu String. Bill id
transactionlist.errorCodeKiểu String. Mã lỗi
transactionlist.errorDescKiểu String. Mô tả mã lỗi
transactionlist.mBReferenceNumberKiểu String. Số tham chiếu FT
transactionlist.statusKiểu String. Trạng thái của bill. Tham khảo mục Bill_payment_status
transactionlist.transactionPaymentIdKiểu String. Số duy nhất do MB sinh ra để định danh giao dịch

Thử nghiệm

Tham khảo