Xpress

Faspay xpress is another way to integrate with Faspay business services, the difference is the payment channel option is on the Faspay page.

Basic integration process of faspay xpress will be explained below.

Integration Step

  1. Post Data Transaction

  2. callback/return URL (for one step transaction)

  3. Payment Notification

1. Post Data Transaction

Endpoint URL Post Data

Endpoint URL is used as a feedback URL that will process the data in the post from the merchant system. There are two URLs that needs to be used, namely Production and Development. For the implementation of the testing or UAT can use the URL development

Request Parameter
Sample Request
Request Parameter

No

Parameter

Type

Lenght

Required

Description

1

Merchant_id

N

5

M

Merchant code from faspay

2

Merchant_name

AN

32

M

Merchant Name

3

order_id

AN

32

M

Order Number

4

order_reff

AN

32

O

Booking Number/reffrence (can fill same with order no)

5

bill_date

Datetime

M

Transaction/Order Date

6

bill_expired

Datetime

M

Transaction/Order Expiry Date

7

bill_desc

AN

128

M

Transaction Description

8

bill_gross

N

15

O

Order Nominal

9

bill_miscfee

N

15

O

Miscellaneous fee

10

bill_total

N

15

M

Total Nominal

11

custNo

AN

32

M

Customer Number

12

return_url

AN

32

M

url using to return to merchant website (*channel credit card)

13

custName

AN

32

O

Customer Name

14

custPhone

N

128

O

Customer Mobile Phone

15

custEmail

AN

128

M

Customer Email

16

billingAddress

AN

200

O

Billing Address

17

billingCity

AN

50

O

Billing City

18

BillingRegion

AN

100

O

Billing Addres Region

19

billingState

AN

100

O

Billing Address State

20

billingPoscode

AN

10

O

Billing Address PosCode

21

billingCountryCode

AN

10

O

Billing Address Country Code

22

receiver_name

AN

100

O

Receiver Name

23

shippingAddress

AN

200

O

Shipping Address

24

shippingCity

AN

50

O

Shipping Address City

25

shippingRegion

AN

100

O

Shipping Address Region

26

shippingState

AN

100

O

Shipping Address State

27

shippingPostcode

AN

10

O

Shipping AddressPosCode

28

Products

AN

50

M

Items

29

Signature

AN

100

M

sha1(md5(user_id merchant + password merchant + bill_no + bill_total))

30

term_condition

N

1

M

Active Term and Conditions (1=True , 0=False)

Sample Request
$products = array(
array(
'product' => 'Bunga',
'qty' => 1,
'amount' => 450000
),
array(
'product' => 'Coklat',
'qty' => 2,
'amount' => 500000
)
);
$signature = sha1(md5($this->merchant_user.$this->merchant_password.$bill_no));
foreach($products as $rprod => $fprod){ $bill_total += ($fprod["amount"] * $fprod["qty"]); }
$data = serialize($products);
$encoded = htmlentities($data);
$post = array(
"merchant_id" => $this->merchant_id,
"merchant_name" => $this->merchant_name,
"order_id" => $bill_no,
"order_reff" => $bill_no,
"bill_date" => date("Y-m-d H:i:s"),
"bill_expired" => date("Y-m-d H:i:s", strtotime("+1 day")),
"bill_gross" => $bill_total,
"bill_miscfee" => '0',
"bill_total" => $bill_total,
"bill_desc" => 'Purchase Orders',
"custNo" => '01',
"return_url" => 'https://alamatwebsite.com/response',
"custName" => 'Tester',
"custPhone" => '085881130118',
"custEmail" => '[email protected]',
"billingAddress" => 'Jl. Pintu Air Raya No 2A',
"billingState" => 'Indonesia',
"billingCity" => 'Jakarta Pusat',
"billingRegion" => 'DKI Jakarta',
"billingPostcode" => '10710',
"billingCountryCode" => 'ID',
"receiver_name" => 'Tester',
"shippingAddress" => 'Jl. Pintu Air Raya No 2A',
"shippingState" => 'Indonesia',
"shippingCity" => 'Jakarta Pusat',
"shippingRegion" => 'DKI JAKARTA',
"shippingPostCode" => '10710',
"klik_pay_code" => $this->klikpay_code,
"clear_key" => $this->clear_key,
"server" => $this->server,
"mixed" => 0,
"mid_full" => '100001',
"mid_tiga_bulan" => '100003',
"mid_enam_bulan" => '100006',
"mid_duabelas_bulan" => '100012',
"mid_duaempat_bulan" => '100024',
"cicilan_enam_bulan" => 1,
"cicilan_tiga_bulan" => 1,
"cicilan_duabelas_bulan" => 1,
"cicilan_duaempat_bulan" => 1,
"products" => $encoded,
"signature" => $signature,
"term_condition" => 1,
);

For every valid post data will get result like example bellow :

xpress purchase detail page
xpress payment method page

2. Callback/Return URL

After the customer completes the payment via bank's website, the bank website automatically redirect customer to Callback/Return URL. Please provide the URL and make sure it's already register on Faspay system. For the detail reference can be find Here

3. Payment Notification

Payment notification from Faspay to Merchant backend will also be triggered on event of transacion status getting updated, to ensure merchant is securely informed. Please provide the URL and make sure it's already register on Faspay system

The detail API reference can be find here