Skip to main content

Method POST

Melakukan pembelian produk menggunakan Metode POST melalui api versi 2

Endpoint

https://v1.apigames.id/v2/transaksi

HTTP Method

POST

Request

Deskripsi

Berikut adalah struktur JSON yang diharapkan:

ParameterDeskripsiTipe DataWajib
ref_idRef ID unik AndaStringYa
merchant_idMerchant ID Anda Lihat Pengaturan Secret KeyStringYa
produkKode Produk Bisa menggunakan prefix custom misalnya AGML80 untuk produk ML80StringYa
tujuanTujuan PengisianStringYa
server_idIsi string kosong "" jika produk tidak memiliki Server ID Lihat ProdukStringYa
signatureSignature dengan formula md5(merchant_id:secret_key:ref_id)StringYa

Contoh

{
"ref_id": "T220926XXXXX00003",
"merchant_id": "M220718CYXXXXX3KFF",
"produk": "ff5",
"tujuan": "4645",
"server_id": "",
"signature": "fa375f4e3dsdbe2cdcf5d1ee0e9d678ad"
}

Response

Deskripsi

Contoh Response

{
"data": {
"merchant_id": "M220718CYXXXXX3KFF",
"trx_id": "T220926XXXXX00003",
"ref_id": "sdfsdx2",
"destination": "4645",
"product_code": "ff5",
"product_code_master": "ff5",
"message": "R#sdfsdx2 ff5.4645, status PENDING. BSK.AFULP. RefId : 12067803053055289057. Sisa saldo 99049000",
"status": "Pending",
"sn": "BSK.AFULP. RefId : 12067803053055289057",
"last_balance": "99049000",
"product_detail": {
"name": "5 Diamond Free Fire",
"code": "ff5",
"price": 3,
"price_unit": "garena shell",
"rate": 250,
"price_rp": 750
}
},
"status": 1
}

Contoh Response Error

{
"error_msg": "Signature not valid",
"status": 0
}