Skip to content

Xendit Invoices

Invoice Introduction

Xendit Invoices are one of our core products that is useful to boost your payment and sales by providing seamless payment experience to your customers for one time payments, subscriptions, or something in between. Xendit Invoices automatically detect payments instantly and can be paid from any banks.

We provide Xendit Invoices for free and you can create it anytime using both Xendit Dashboard and the invoice API. Xendit Invoices UI can be used directly, can be used as a checkout page for eCommerce businesses, or can be integrated with your own payment UI. If you choose to use our UI, this is how an invoice will look like from the end customer’s point of view:

alt text

The invoices can be opened from both web and mobile-web, support multi language and it will show all of your available payment methods and instructions for the end customers, giving them convenient flexibility and a positive impact for your sales.

Congratulations! you've learned about the invoices

Next Step: If you keep scrolling, you will learn more about:


Workflow

Once the payment has been successfully completed, Xendit detects the incoming payment and sends the callback. The incoming funds will show up in the Xendit Dashboard as a balance in the Cash Account, and the invoice status in the Invoice tab will also be updated.

alt text


Features and limitation

Features

Features Description
Multiple payment channels Customisable channels. (Cards, Banks VA, retail, e-wallet)
Automatic Notification Callback URL to your business, email to end customers
Free and Customisable UI No building, we create it for you and it’s customizable: Business logo, business name, description, language, color, font, and payment channels
Adjustable Expiration date You can set different expiration date per your invoice. The control is in your hand
Live Report in Xendit dashboard Dashboard to do reconciliation.
Updated payment instructions We always provide latest “how to pay” instructions for your end customer. We will always keep it simple for you to receive payments
With or without API integration Invoice creation via dashboard or automated creation via API

Channels

Xendit invoice can receive and detect payments from all Indonesian banks, international cards, retail outlets and e-wallet. Simple and easy integration with our invoice system will enable your business to receive payment from all those method.

alt text

Limitation

Before you create an invoice, please make sure you didn’t exceed the invoice limitation:

Condition Limitation
Maximum amount per invoice IDR 1.000.000.000
Minimum amount per invoice IDR 10.000
Maximum amount for Retail Outlet IDR 5.000.000

If you create invoice more than IDR 5.000.000, Retail Outlet will be disabled for that specific invoice


Setting up your invoice

If you already have access to live transaction and you want to use VA on live environment, you can do it by enabling your bank VA range Dashboard > Settings > Configuration > Invoice by clicking "activate" button. If you are not live yet, don't forget to activate the VA after you are going live.

Before you create your invoice for the first time, you might want to do some setting and customize your invoice. You can visit Dashboard > Invoice > Custom Invoice and make your own setup.

Description What will change
Color Set your primary and secondary color of your invoice
Font Set the font of your invoice
Default Language First language that your customer will see (Your customer can change it by their own)
Default Invoice Duration Default duration of the invoice. (You can also custom duration per invoice while creating an invoice)
Default Payment Method Choose your default and primary payment method. (You can also custom payment channel per invoice while creating an invoice via API)

To increase your customer trust, you also need to setup your business logo and business name on Dashboard > Settings > General

alt text


Notification and Callback

Email Notifications

If you choose "send invoice to this email" during the invoice creation, your customer will receive an email when:

  • The invoice created
  • The invoice is either paid or expired

alt text

As a merchant, you can also choose to receive an email notification for a paid and expired invoice. If you decided to do so, you can contact us and we will enable it for you.

Callback URL

Currently we can give a callbacks when the invoice is paid and expired, please ensure that the callback URLs for Invoices has been set. You can configure the callback URL in your Dashboard > Settings > Configuration > Invoice. Below is an example of where to set up callback URL for Invoice:

alt text

Callback URL needs to be a HTTPS with SSL (Standard Socket Layer), which is our standard security protocol test. Callback will work if the callback URL you put is in the right format. Below is the example how to implement callback from your side:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
<?php
    if ($_SERVER["REQUEST_METHOD"] === "POST") {
        $data = file_get_contents("php://input");
        print_r("\n\$data contains the updated invoice data \n\n");
        print_r($data);
        print_r("\n\nUpdate your database with the invoice status \n\n");
    } else {
        print_r("Cannot ".$_SERVER["REQUEST_METHOD"]." ".$_SERVER["SCRIPT_NAME"]);
    }
?>

Create invoice via dashboard

Creating invoices using Xendit Dashboard is very simple. Every Xendit Invoices created will be on the dashboard with it's status and details. First, go to the dashboard invoice tab where you can find a “+ Create invoice” button there. When you click it, it will open a pop-up where you can fill:

Parameter What to fill
External ID Unique code for you to reconcile. e.g.:
  • HOUSE.AP/INV/XXV/34
  • 1293
  • TPR0004
  • XJEDBDIEFDJIAGDY
Email Email of your customer (the one you want to bill). You can choose whether Xendit send email to your customer or not
Invoice due time Click on calendar icon to choose the date and then inside calendar, click clock icon to set the time
Amount Invoice total amount in Rupiah
Description Short description for your end customer to read. (e.g. Payment for apartment electricity bill unit #0521G)

After you filled all the forms and created an invoice, you will also get the link for your invoice. If you choose “Send invoice to this email”, Xendit will automatically send an email to your customer. You can also copy the link and send it directly to your customer. The end customer can pay the invoice by choosing the payment options and following the given payment instructions.


Create invoice via API

If you are not technical enough, you can skip this step. If you understand how API works and you want to create an invoice using an API, you can visit our full API documentation at invoice API docs. To learn about the integration, you can also visit Integration. For testing, you can try to use Postman.

If you choose to use Xendit invoice UI, you can just get the invoice link from our response and embed it into your button or anywhere you want. By using API, You can also create your own User Interface and your own checkout or payment page. Our response will return data that you can use for your own UI. Ignore the invoice link and get other data that suits your need.

Let’s try to create an invoice which we will then pay so you can see how our invoice flow works. You can follow the steps below to implement our invoices API. You’ll need to POST this request. It will create an invoice which your customers can pay with the methods you have configured within the dashboard.

1
2
3
4
5
6
curl https://api.xendit.co/v2/invoices -X POST \
    -u xnd_development_O46JfOtygef9kMNsK+ZPGT+ZZ9b3ooF4w3Dn+R1k+2fT/7GlCAN3jg==: \> 
    -d external_id=demo-1531960366017 \
    -d payer_email=sample_email@xendit.co \
    -d description='Trip to Bali' \
    -d amount=52000
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
<?php 
    require 'vendor/autoload.php'; 
    $options['secret_api_key'] = 'xnd_development_O46JfOtygef9kMNsK+ZPGT+ZZ9b3ooF4w3Dn+R1k+2fT/7GlCAN3jg=='; 
    $xenditPHPClient = new XenditClient\XenditPHPClient($options); 
    $external_id = 'demo_1475801962607';
    $payer_email = 'sample_email@xendit.co';
    $description = 'Trip to Bali';
    $amount = 13000;
    $response = $xenditPHPClient->createInvoice($external_id, $amount, $payer_email, $description);
    print_r($response); 
?>

We have prefilled the above example with a sample API key and other filled parameter. You need to change the content of the parameter above with your desired parameter. You can also add optional parameter such as redirection link page, invoice duration and payment methods. The description of the parameter also can be found in invoice API docs.


Simulate Payment in test mode

Test Xendit integration thoroughly by simulating payment to your invoice! This simulation will result in your invoice status showing up as Paid/Settled in your Dashboard. We also initiate a callback to your Callback URL.

Simulate via testing amount

  1. Create any invoice with the amount of IDR 3,000,000
  2. Go to your dashboard for the transaction details
  3. Invoice is successfully paid

Simulate via cards

  1. Create any invoice (make sure cards payment method is enabled)
  2. Open the invoice
  3. Go to the cards tab inside the invoice
  4. Fill the card number with 4000 0000 0000 0002, any CVV and future expiry date
  5. Invoice is successfully paid

Frequently Asked Questions

  1. How do I know if my invoice is paid?

    • The status of the invoice shows up as PAID/SETTLED on your dashboard
    • We send a callback to you for the payment
  2. How do I know when an invoice expires?

    • When an invoice expires, you are able to see the status on your dashboard on the Invoices menu
    • Invoice can't be paid anymore and invoice UI is disabled.
    • If you tick the flag to send the invoice to your customer, email notification will be sent to your customer when the invoice expires, and they will be informed not to make payment
    • Send us a GET Invoice Request with API to see your invoice status
  3. What to do with an expired invoice? How do I know if someone paid to it?

    When an invoice expires, you can disregard it and make a new one. Expired invoices cannot be paid.

  4. What to do when my customer paid a wrong amount to the invoice?

    Virtual Accounts in invoice will always be closed amount, hence your customer will not be able to pay a wrong amount to the invoice

  5. Can I set customized expiration time of my invoice?

    Yes, with a maximum 1 (one) year expiry date that you could customize upon invoice creation, from Xendit dashboard or from an API. This is an optional setting, that you can leave it blank for your default invoice duration to be applied. However, please note that the invoices that have been generated cannot be altered, although you can expire the invoice to make it redundant so that your customer cannot pay it.

  6. Which user can create invoices on dashboard?

    Users who can create invoice are those with the permission to edit.

  7. How to set Banks and payment methods on my invoices?

    You can change it directly from dashboard. Some payment method may require you to enable it first, you can contact us to help you enable it.

  8. How do I set types of Virtual Account on my Invoices?

    Currently you may only set this via API. You can also inform us in advance to set it for you.

  9. How do I put my company name and picture on my invoices?

    If you are using Xendit Invoices UI, you can put your company name and picture on your dashboard, go to Settings, upload your Business Logo and set Business Information. Your Invoice details will be in accordance to your configurations.

  10. Can I use my own UI for Xendit Invoices?

    Yes, you can use your own UI by integrating with our API.

  11. Is credit card payment a default payment method or should we configure it first?

    It is default and automatically appears on the invoice as one of payment methods option for customer.


Quick Setup

TLDR: If you decided to skip all information above and you want something quick and simple, you can follow these steps for quick setup:

  1. Set your business logo and name on Dashboard > Settings > General
  2. Decide whether you will use an API or dashboard
    1. If you use API
      1. Use documentation Invoice API docs
      2. Set your callback Dashboard > Settings > Configuration > Invoice
    2. If you use dashboard Dashboard > Invoice
  3. When you go live, activate VA that you want Dashboard > Settings > Configuration > Invoice
  4. Setting your default invoice on Dashboard > Invoice > Custom Invoice
  5. Paid and Expired invoice will be updated on your dashboard invoice page