Class EWalletPayment


  • public class EWalletPayment
    extends java.lang.Object
    • Constructor Detail

      • EWalletPayment

        public EWalletPayment()
    • Method Detail

      • createLinkajaPayment

        public static EWalletPayment createLinkajaPayment​(java.lang.String externalId,
                                                          java.lang.Number amount,
                                                          java.lang.String phone,
                                                          EWalletLinkajaItem[] items,
                                                          java.lang.String callbackUrl,
                                                          java.lang.String redirectUrl)
                                                   throws XenditException
        Create new payment for LINKAJA
        Parameters:
        externalId - An ID of your choice. Often it is unique identifier like a phone number, email or transaction ID. Maximum length allowed is 1000 characters.
        amount - Amount end-customer will pay.
        phone - Phone number of end-customer (e.g. 08123123123)
        items - List of items / products.
        callbackUrl - The URL to receive the callback after payment made by end-customer
        redirectUrl - The URL to redirect to after payment made by end-customer
        Returns:
        EWalletPayment model.
        Throws:
        XenditException - XenditException
      • createOvoPayment

        public static EWalletPayment createOvoPayment​(java.lang.String externalId,
                                                      java.lang.Number amount,
                                                      java.lang.String phone)
                                               throws XenditException
        Create new payment for OVO
        Parameters:
        externalId - An ID of your choice. Often it is unique identifier like a phone number, email or transaction ID. Maximum length allowed is 1000 characters.
        amount - Amount end-customer will pay.
        phone - Phone number of end-customer (e.g. 08123123123)
        Returns:
        EWalletPayment model.
        Throws:
        XenditException - XenditException
      • createDanaPayment

        public static EWalletPayment createDanaPayment​(java.lang.String externalId,
                                                       java.lang.Number amount,
                                                       java.lang.String phone,
                                                       java.lang.String expirationDate,
                                                       java.lang.String callbackUrl,
                                                       java.lang.String redirectUrl)
                                                throws XenditException
        Create new payment for DANA
        Parameters:
        externalId - An ID of your choice. Often it is unique identifier like a phone number, email or transaction ID. Maximum length allowed is 1000 characters.
        amount - Amount end-customer will pay.
        phone - Phone number of end-customer (e.g. 08123123123)
        expirationDate - End-customer cannot complete the payment past the expiration date
        callbackUrl - The URL to receive the callback after payment made by end-customer
        redirectUrl - The URL to redirect to after payment made by end-customer
        Returns:
        EWalletPayment
        Throws:
        XenditException - XenditException
      • getPaymentStatus

        public static EWalletPayment getPaymentStatus​(java.lang.String externalId,
                                                      EWalletPayment.EWalletType ewalletType)
                                               throws XenditException
        Parameters:
        externalId - An ID of your choice. Often it is unique identifier like a phone number, email or transaction ID.
        ewalletType - The type of ewallet to be paid. Must be in capital letters.
        Returns:
        EWalletPayment model.
        Throws:
        XenditException - XenditException
      • createPaymentRequest

        public static EWalletPayment createPaymentRequest​(java.util.Map<java.lang.String,​java.lang.String> headers,
                                                          java.util.Map<java.lang.String,​java.lang.Object> params)
                                                   throws XenditException
        Throws:
        XenditException