digiflazz-sdk
TypeScript icon, indicating that this package has built-in type declarations

0.1.11 • Public • Published

Digiflazz Client Library

Installation

pnpm add digiflazz-sdk
# or
npm install digiflazz-sdk
# or
yarn add digiflazz-sdk

API

Create Digiflazz Config

import createDigiflazzConfig from "digiflazz-sdk"

const digiflazz = createDigiflazzConfig({
    username: [your digiflazz username],
    key: [your digiflazz api key]
})

Cek Saldo

const amount = await digiflazz.cekSaldo(
    'prepaid | pasca'
);

Daftar Harga

const priceList = await digiflazz.daftarHarga();

Tiket Deposit

const deposit = await digiflazz.deposit({
    amount: 'nominal',
    bank: 'bank',
    name: 'bank account own name'
});

Transaksi Top Up

const topup = await digiflazz.transaksi({
    sku: 'sku',
    customerNo: 'customer order number',
    refId: 'reference id',
    cmd: 'null | pay-pasca | inq-pasca | status-pasca | pln-subscribe'
    testing: boolean
    msg: 'message'
});

NOTE:

  • inq-pasca: cek tagihan
  • pay-pasca: bayar tagihan
  • status-pasca: cek status tagihan
  • pln-subscribe: cek id pln
  • if the transaction isn't in seller mode dont use cmd.

Webhook (Coming Soon)

Seller Area (Coming Soon)

Readme

Keywords

none

Package Sidebar

Install

npm i digiflazz-sdk

Weekly Downloads

26

Version

0.1.11

License

MIT

Unpacked Size

19.6 kB

Total Files

6

Last publish

Collaborators

  • karyanayandi