1. Mobile
English
  • EspaΓ±ol
  • English
  • PerΓΊ πŸ‡΅πŸ‡ͺ
    • Kushki Developer Portal πŸš€
    • PerΓΊ πŸ‡΅πŸ‡ͺ
    • Libraries & SDKs (Online Payments)
      • Release notes
      • Mobile
        • Kushki iOS ARM Setup
        • Kushki iOS ο£Ώ
        • Kushki Android
      • Web
        • Kushki.js 🌐
        • kushki.js-hosted-fields
          • GuΓ­a de migraciΓ³n a Kushki.js 2.0
          • kushki.js Hosted Fields
          • Antifraud
            • Interfaces
              • SecureInitRequest
              • SecureInitResponse
              • SiftScienceObject
            • Methods
              • requestSecureInit
              • requestInitAntiFraud
              • requestValidate3DS
          • Card
            • CarApplePay interface
              • ICardApplePay Interface
            • Card-Interface
              • ICard Interface
              • ICardSubscriptions Interface
            • Errors
              • Error list
            • Interfaces
              • TokenResponse
              • AppleTokenResponse
              • FormValidity
              • Styles
              • BrandByMerchantResponse Interface
              • ApplePayOptions Interface
              • ApplePayPaymentContact
              • ApplePayGetTokenOptions Interface
              • Amount
              • SecureDeviceTokenOptions
              • MasterCardBrandingRequest
              • CardOptions
              • Fields
              • FieldInstance
              • Field
              • DeferredInputValues
              • FieldValidity
              • DeferredValuesResponse
              • DeferredByBinOptionsResponse
              • DeviceTokenRequest
              • VisaBrandingRequest
              • CardFieldValues
              • CardTokenResponse
              • CardInfo
            • Methods
              • initSecureDeviceToken
              • initApplePayButton
              • requestDeviceToken method
              • requestInitCardBrandingAnimation
              • initCardToken
              • requestBrandsByMerchant method
            • Types
              • CssProperties
              • Currency
              • FieldTypeEnum
          • Card Payouts
            • Card Payouts Interface
              • ICardPayouts
            • Enumerations
              • Enumeration `InputModelEnum`
            • Errors
              • Errors
            • Interfaces
              • Interface FormValidity
              • Interface `Styles`
              • CardPayoutUniqueTokenResponse
              • CardPayoutSubscriptionTokenResponse
              • CardPayoutOptions
              • Fields
              • Field
              • FieldValidity
            • Methods
              • initCardPayoutToken
            • Type Aliases
              • InputTypeEnum
              • CardPayoutTokenResponse
            • Types
              • CssProperties
          • Kushki
            • Methods
              • requestBankList function
              • requestCommissionConfiguration function
              • init function
            • Classes
              • KushkiError
            • Interfaces
              • IKushki
              • CommissionConfigurationRequest
              • KushkiOptions
    • Schemas
      • API Raw Card Present
        • metadata
        • extra_taxes
        • card
        • sub_merchant
        • pos_details
        • enc_tlv
        • deferred
        • contact_details
        • card_details
        • amount
      • one-and-two-step-payment
      • webhooksChargeback
      • webhooks
      • transactionType
      • threeDomainSecure
      • product
      • payment_submethod
      • paymentMethod
      • orderDetails
      • headers
      • extraTaxes
      • documentType
      • currency
      • currency-cash-in
      • currency-CL
      • binInfo
      • UnexpectedErrorResponse
      • SubscriptionUpdate
      • SubscriptionAdjustmentRequest
      • Subscription
      • Submerchant
      • Shipping-Address
      • Promotions
      • Metadata
      • Language
      • InvalidBinResponse
      • GetConfigurationRequest
      • ErrorResponse
      • Deferred
      • Country
      • ContactDetails
      • ChargesVoidCardResponse
      • Channel
      • Card
      • Billing-Address
      • BadRequestResponse
      • Amount
      • Amount-cash-in
      • Amount-CL
  • APPIAN-SUBMERCHANT-REGISTER
    • Submerchant Validation in Batch
    • Query submerchant status by requestId/submerchantId
    • Get submerchantIds
    • Get credentials for submerchants
  • MΓ©xico πŸ‡²πŸ‡½
    • Bienvenidos
    • CARD PRESENT PAYMENTS (API RAW) Copy Copy
      • error-catalog
      • Test data
      • One-time payments
        • Single payment
      • Two-step-payments
        • Authorization and capture
      • Voids & Refunds
        • Void & Reverse
        • Refund a transaction
      • Card information
        • Balance inquiries
        • Get BIN Info
        • BIN info V2
        • Request deferred options
      • Query Transactions
        • Transaction Search
    • ONLINE PAYMENTS
      • CARD
        • CARD
        • 1. Request a card token
        • 2. Make a charge or deferred charge
        • 3. Void a transaction
        • 4. Refund a transaction
        • 5. Request deferred options
        • 6. Authorize payments
        • 7. Reauthorize payments
        • 8. Capture an authorized payment
        • 9. Bin Info
        • 10. Bin Info V2
        • 11. Validate OTP
        • 12. Verify Account
        • 12. Verify Account
        • 6. Authorize payments
        • 10. Bin Info V2
        • 8. Capture an authorized payment
        • 3. Void a transaction
        • 4. Refund a transaction
        • 7. Reauthorize payments
        • 1. Request a card token
        • 9. Bin Info
        • 5. Request deferred options
        • 2. Make a charge or deferred charge
        • 11. Validate OTP
      • CASH IN
        • 1. Request a cash in token
        • 2. Init Transaction
        • 3. Transaction Status
        • 1. Request a cash in token
        • 2. Init Transaction
        • 3. Transaction Status
      • TRANSFER IN
        • 1. Request a Transfer In token
        • 2. Init Transaction
        • 4. Get Status Copy
        • 1. Request a Transfer In token
        • 4. Get Status Copy
        • 2. Init Transaction
      • TRANSFER OUT
        • 1. Get Bank List
        • 2. Request a Transfer Out token
        • 3. Init Transaction
        • 4. Get Status
        • 5. Wallet Balance
        • 5. Wallet Balance
        • 1. Get Bank List
        • 4. Get Status
        • 2. Request a Transfer Out token
        • 3. Init Transaction
      • ONE-CLICK & SCHEDULED PAYMENTS
        • 1. Request a recurring charge token
        • 2. Create a recurring charge
        • 3. Update recurring charge card data
        • 4. Make an One-click payment
        • 5. Cancel a recurring charge
        • 6. Update a recurring charge
        • 7. Add a temporary charge or discount
        • 8. Authorize payments Copy
        • 9. Capture an authorized payment Copy
        • 10. Get recurring charge Info
        • 1. Request a recurring charge token
        • 8. Authorize payments Copy
        • 3. Update recurring charge card data
        • 6. Update a recurring charge
        • 10. Get recurring charge Info
        • 2. Create a recurring charge
        • 5. Cancel a recurring charge
        • 9. Capture an authorized payment Copy
        • 4. Make an One-click payment
        • 7. Add a temporary charge or discount
      • PAYMENT BUTTON
        • 1. Create a payment button
        • 1. Create a payment button
      • SMARTLINKS V2
        • 1. Create a Smartlink
        • 2. Get a Smartlink
        • 3. Delete a Smartlink
        • 4. Update a Smartlink
        • 1. Create a Smartlink
        • 4. Update a Smartlink
        • 2. Get a Smartlink
        • 3. Delete a Smartlink
      • PAYMENT CREDENTIALS
        • 1. Create a credential
        • 2. Search credentials
        • 3. Advanced search
        • 4. Activate or deactivate
        • 5. Delete credential
        • 6. Update credential
        • 7. Regenerate a credential
        • 3. Advanced search
        • 6. Update credential
        • 5. Delete credential
        • 2. Search credentials
        • 4. Activate or deactivate
        • 7. Regenerate a credential
        • 1. Create a credential
      • COMMISSIONS
        • 1. Get Commission Configuration
        • 1. Get Commission Configuration
      • GATEWAY STATUS
        • 1. Get gateway status
        • 1. Get gateway status
      • ANALYTICS
        • 1. Get transactions list
        • 1. Get transactions list
    • CARD PRESENT PAYMENTS (BILLPOCKET)
      • Get token
      • States
      • Validate token
      • Municipalities
      • Collect payments
      • Tax companies
      • Capture an authorized payment
      • Commercial activities
      • Refund
      • Create checkout
      • Get status
      • Get checkout details
      • Collect card payments
      • Print Ticket
      • Collect card payments v2
      • Cancel Push Notification
      • Get transaction status
      • Add or update CLABE account
      • Configure payment link
      • Get payment link configuration
      • Create payment link
      • Update payment link
      • List payment links
      • Delete payment link
      • Add CLABE account
      • Get token
      • Get transaction list
      • Get transaction list v2
      • Get transaction list v3
      • Get transaction list v4
      • Create user
  • Ecuador πŸ‡ͺπŸ‡¨
    • Bienvenidos
    • ONLINE PAYMENTS
      • CARD
        • 1. Request a card token
        • 2. Make a charge or deferred charge
        • 3. Void a transaction
        • 4. Refund a transaction
        • 5. Request deferred options
        • 6. Bin Info
        • 7. Bin Info V2
        • 8. Validate OTP
        • 7. Bin Info V2
        • 1. Request a card token
        • 4. Refund a transaction
        • 8. Validate OTP
        • 3. Void a transaction
        • 2. Make a charge or deferred charge
        • 5. Request deferred options
        • 6. Bin Info
      • ONE-CLICK & SCHEDULED PAYMENTS
        • 1. Request a recurring charge token
        • 2. Create a recurring charge
        • 3. Update recurring charge card data
        • 4. Make an One-click payment
        • 5. Cancel a recurring charge
        • 6. Update a recurring charge
        • 7. Add a temporary charge or discount
        • 8. Get recurring charge Info
        • 7. Add a temporary charge or discount
        • 4. Make an One-click payment
        • 3. Update recurring charge card data
        • 6. Update a recurring charge
        • 5. Cancel a recurring charge
        • 1. Request a recurring charge token
        • 8. Get recurring charge Info
        • 2. Create a recurring charge
      • TRANSFER IN
        • 1. Get Bank List
        • 2. Request a Transfer In token
        • 3. Init Transaction
        • 4. Get Status
        • 4. Get Status
        • 2. Request a Transfer In token
        • 3. Init Transaction
        • 1. Get Bank List
      • CASH IN
        • 1. Request a cash in token
        • 2. Init Transaction
        • 3. Transaction Status
        • 4. Update a cash in transaction
        • 5. Delete a cash in transaction
        • 1. Request a cash in token
        • 3. Transaction Status
        • 5. Delete a cash in transaction
        • 2. Init Transaction
        • 4. Update a cash in transaction
      • SMARTLINKS V2
        • 1. Create a Smartlink
        • 2. Get a Smartlink
        • 3. Delete a Smartlink
        • 4. Update a Smartlink
        • 3. Delete a Smartlink
        • 1. Create a Smartlink
        • 2. Get a Smartlink
        • 4. Update a Smartlink
      • ANALYTICS
        • 1. Get transactions list
        • 1. Get transactions list
      • GATEWAY STATUS
        • 1. Get gateway status
        • 1. Get gateway status
      • COMMISSIONS
        • 1. Get Commission Configuration
        • 1. Get Commission Configuration
      • PAYMENT CREDENTIALS
        • 1. Create a credential
        • 2. Search credentials
        • 3. Advanced search
        • 4. Activate or deactivate
        • 5. Delete credential
        • 6. Update credential
        • 7. Regenerate a credential
        • 1. Create a credential
        • 7. Regenerate a credential
        • 3. Advanced search
        • 6. Update credential
        • 5. Delete credential
        • 4. Activate or deactivate
        • 2. Search credentials
      • PAYMENT BUTTON
        • 1. Create a payment button
        • 1. Create a payment button
  • Chile πŸ‡¨πŸ‡±
    • Bienvenidos
    • ONLINE PAYMENTS
      • CARD
        • 1. Request a card token
        • 2. Make a charge or deferred charge
        • 3. Void a transaction
        • 4. Refund a transaction
        • 5. Request deferred options
        • 6. Authorize payments
        • 7. Capture an authorized payment
        • 8. Bin Info
        • 9. Bin Info V2
        • 10. Validate OTP
        • 11. Voucher
        • 5. Request deferred options
        • 8. Bin Info
        • 10. Validate OTP
        • 3. Void a transaction
        • 4. Refund a transaction
        • 6. Authorize payments
        • 1. Request a card token
        • 7. Capture an authorized payment
        • 11. Voucher
        • 2. Make a charge or deferred charge
        • 9. Bin Info V2
      • CASH IN
        • 1. Request a cash in token
        • 2. Init Transaction
        • 3. Transaction Status
        • 1. Request a cash in token
        • 2. Init Transaction
        • 3. Transaction Status
      • TRANSFER IN
        • 1. Get Bank List
        • 2. Request a Transfer In token
        • 3. Init Transaction
        • 4. Get Status
        • 1. Get Bank List
        • 4. Get Status
        • 2. Request a Transfer In token
        • 3. Init Transaction
      • TRANSFER OUT
        • 1. Get Bank List
        • 2. Request a Transfer Out token
        • 3. Init Transaction
        • 4. Get Status
        • 5. Wallet Balance
        • 2. Request a Transfer Out token
        • 1. Get Bank List
        • 5. Wallet Balance
        • 3. Init Transaction
        • 4. Get Status
      • ONE-CLICK & SCHEDULED PAYMENTS
        • 1. Request a recurring charge token
        • 2. Create a recurring charge
        • 3. Update recurring charge card data
        • 4. Make an One-click payment
        • 5. Cancel a recurring charge
        • 6. Update a recurring charge
        • 7. Add a temporary charge or discount
        • 8. Authorize payments
        • 9. Capture an authorized payment
        • 10. Get recurring charge Info
        • 3. Update recurring charge card data
        • 7. Add a temporary charge or discount
        • 10. Get recurring charge Info
        • 5. Cancel a recurring charge
        • 6. Update a recurring charge
        • 4. Make an One-click payment
        • 9. Capture an authorized payment
        • 8. Authorize payments
        • 2. Create a recurring charge
        • 1. Request a recurring charge token
      • PAYMENT BUTTON
        • 1. Create a payment button
        • 1. Create a payment button
      • SMARTLINKS V2
        • 1. Create a Smartlink
        • 2. Get a Smartlink
        • 3. Delete a Smartlink
        • 4. Update a Smartlink
        • 3. Delete a Smartlink
        • 4. Update a Smartlink
        • 1. Create a Smartlink
        • 2. Get a Smartlink
      • PAYMENT CREDENTIALS
        • 1. Create a credential
        • 2. Search credentials
        • 3. Advanced search
        • 4. Activate or deactivate
        • 5. Delete credential
        • 6. Update credential
        • 7. Regenerate a credential
        • 6. Update credential
        • 5. Delete credential
        • 4. Activate or deactivate
        • 2. Search credentials
        • 1. Create a credential
        • 3. Advanced search
        • 7. Regenerate a credential
      • COMMISSIONS
        • 1. Get Commission Configuration
        • 1. Get Commission Configuration
      • GATEWAY STATUS
        • 1. Get gateway status
        • 1. Get gateway status
      • ANALYTICS
        • 1. Get transactions list
        • 1. Get transactions list
      • ASYNC CARD RECURRING CHARGES
        • 1. Request a token
        • 2. Init an async card recurring charge
        • 3. Authorize payments
        • 4. Capture an authorized payment
        • 2. Init an async card recurring charge
        • 4. Capture an authorized payment
        • 1. Request a token
        • 3. Authorize payments
      • CARD ASYNC
        • 1. Request a card async token
        • 2. Init Transaction
        • 3. Authorize payments Copy
        • 4. Capture an authorized payment Copy
        • 5. Get Status
        • 4. Capture an authorized payment Copy
        • 5. Get Status
        • 3. Authorize payments Copy
        • 2. Init Transaction
        • 1. Request a card async token
    • CARD PRESENT PAYMENTS (API RAW) Copy
      • error-catalog
      • Test data
      • One-time payments
        • Single payment
      • Two-step-payments
        • Authorization and capture
      • Voids & Refunds
        • Void & Reverse
        • Refund a transaction
      • Card information
        • Balance inquiries
        • Get BIN Info
        • BIN info V2
        • Request deferred options
      • Query Transactions
        • Transaction Search
  1. Mobile

Kushki Android

The Kushki library for Android allows you to collect payments easily and safely in your Android mobile application.
TIP
We make it easier!
We make it easier! This library handles the complexity of secure payments so you can focus on your app experience.

βš™οΈ Install and configure#

To use 3DS, add the following Maven repository and credentials to your app-level gradle file.
Installing the Kushki Android library is simple; add the following code to your project's build.gradle file, inside the dependencies section.

πŸ› οΈ Usage#

After you finish installing, create an instance of Kushki. This will allow you to perform all the methods available in the SDK.

Configuration Parameters#

Required
PropertyTypeDescriptionDefaultPossible Values
publicMerchantIdStringKushki ID created for your merchant.--
currencyStringCurrency code.USDUSD, COP, CLP, UF, PEN, MXN
Optional
PropertyTypeDescriptionDefaultPossible Values
environmentEnumValue to define if you are in production or test environmentKushkiEnvironment.productionKushkiEnvironment.production , KushkiEnvironment.testing
regionalBooleanDefine if use a static IP to Kushki accessfalsetrue,false

⚑ Examples
Find the methods available in our Android library along with examples.

One-Time Payment Examples#

Security Note
The token delivered by Kushki only encrypts and sends information. If you want to store the card information for future purchases, go to the Recurring Charges section.
πŸ’³ Card
⏳ Card Async
🍏 Apple Pay
🏦 Transfer In
πŸ’΅ Cash In

requestToken()#

To request a card token, you can use this method


Required

PropertyTypeDescription
cardObjectThe card data collected in a card object
totalAmountDoubleThe amount you are going to collect

Optional

PropertyTypeDescriptionPossible Values
contextContextContext of the current state of the application/object. Required for 3DS and Sift implementations.
activityActivityAn application component that provides a screen with which users can interact in order to do something. Required for 3DS implementations.

3DS#

The requestToken method of the Kushki library on android does what is necessary so that merchants that have 3DS activated can verify transactions through this service.
It is necessary to validate that the specificationVersion is greater than 2.0. in implementations with 3DS.
Response
If the 3DS service is not active, a response similar to the following will be returned when consuming the requestToken method

{
     "token": "PmgVbd100000Pe5VEU098014S84wiTFR"
}

If the 3DS service is active, a response similar to the following will be returned when consuming the requestToken method

{
    "token": "PmgVbd100000Pe5VEU098014S84wiTFR",
    "secureService": "3dsecure",
    "secureId": "a80d6cef-90ad-44ca-a2ef-f244301d5e40",
    "security": {
        "acsURL": "https://0merchantacsstag.cardinalcommerce.com/MerchantACSWeb/creq.jsp",
        "authenticationTransactionId": "o6YMk3mdEoAMVMImUpd0",
        "authRequired": true,
        "paReq": "eyJtZXNzYWdlVHlwZSI6IkNSZXMiLCJtZXNzYWdlVmVyc2lvbiI6IjIuMi4wIiwidGhyZWVEU1NlcnZlclRyYW5zSUQiOiJlODIzYWVhMS1hMjM3LTRkNmQtYjlhNC0yY2JjZGZlYjI1YTYiLCJhY3NUcmFuc0lEIjoiY2Q4MThmNDAtOTc1NC00NmRjLTg1YzgtMWU5MDk2MjY1MmMzIiwiYWNzVWlUeXBlIjoiMDIiLCJjaGFsbGVuZ2VDb21wbGV0aW9uSW5kIjoiTiIsImNoYWxsZW5nZUluZm9IZWFkZXIiOiJQYXltZW50IFNlY3VyaXR5IiwiY2hhbGxlbmdlSW5mb0xhYmVsIjoiQ3JlZGVudGlhbCBTZWxlY3Rpb24iLCJjaGFsbGVuZ2VJbmZvVGV4dCI6IllvdXIgb25saW5lIHBheW1lbnQgaXMgYmVpbmcgc2VjdXJlZCB1c2luZyBDYXJkIE5ldHdvcmsuIFBsZWFzZSBzZWxlY3Qgd2hlcmUgeW91IHdvdWxkIGxpa2UgdG8gcmVjZWl2ZSB0aGUgY29kZSBmcm9tIFlvdXJCYW5rLiIsImNoYWxsZW5nZVNlbGVjdEluZm8iOlt7Im1vYmlsZSI6Ik1vYmlsZSAqKioqKioqKjMyMSJ9LHsiZW1haWwiOiJFbWFpbCAqKioqKioqKioqQGcqKioqLmNvbSJ9XSwiaXNzdWVySW1hZ2UiOnsibWVkaXVtIjoiaHR0cHM6Ly9tZXJjaGFudGFjc3N0YWcuY2FyZGluYWxjb21tZXJjZS5jb20vTWVyY2hhbnRBQ1NXZWIvc2NyZWVucy9pbWFnZXMvQW55QmFua181MTIucG5nIiwiaGlnaCI6Imh0dHBzOi8vbWVyY2hhbnRhY3NzdGFnLmNhcmRpbmFsY29tbWVyY2UuY29tL01lcmNoYW50QUNTV2ViL3NjcmVlbnMvaW1hZ2VzL0FueUJhbmtfNTEyLnBuZyIsImV4dHJhSGlnaCI6Imh0dHBzOi8vbWVyY2hhbnRhY3NzdGFnLmNhcmRpbmFsY29tbWVyY2UuY29tL01lcmNoYW50QUNTV2ViL3NjcmVlbnMvaW1hZ2VzL0FueUJhbmtfNTEyLnBuZyJ9LCJwc0ltYWdlIjp7Im1lZGl1bSI6Imh0dHBzOi8vbWVyY2hhbnRhY3NzdGFnLmNhcmRpbmFsY29tbWVyY2UuY29tL01lcmNoYW50QUNTV2ViL3NjcmVlbnMvaW1hZ2VzL0NhcmRfTmV0d29yay5wbmciLCJoaWdoIjoiaHR0cHM6Ly9tZXJjaGFudGFjc3N0YWcuY2FyZGluYWxjb21tZXJjZS5jb20vTWVyY2hhbnRBQ1NXZWIvc2NyZWVucy9pbWFnZXMvQ2FyZF9OZXR3b3JrLnBuZyIsImV4dHJhSGlnaCI6Imh0dHBzOi8vbWVyY2hhbnRhY3NzdGFnLmNhcmRpbmFsY29tbWVyY2UuY29tL01lcmNoYW50QUNTV2ViL3NjcmVlbnMvaW1hZ2VzL0NhcmRfTmV0d29yay5wbmcifSwic2RrVHJhbnNJRCI6IjJjZWI0NjUxLWUyYzAtNDZjOS04YzAxLWI2ODNjMTM3Nzc5MSIsInN1Ym1pdEF1dGhlbnRpY2F0aW9uTGFiZWwiOiJORVhUIiwiYWNzQ291bnRlckF0b1MiOiIwMDAiLCJleHBhbmRJbmZvTGFiZWwiOiJNb3JlIEluZm9ybWF0aW9uIiwiZXhwYW5kSW5mb1RleHQiOiJIZXJlIGlzIHRoZSBhZGRpdGlvbmFsIGluZm9ybWF0aW9uIHRoYXQgd2UgcHJvdmlkZS4iLCJ3aHlJbmZvTGFiZWwiOiJOZWVkIHNvbWUgaGVscD8iLCJ3aHlJbmZvVGV4dCI6IkhlcmUgaXMgdGhlIGhlbHAgdGhhdCB3ZSBwcm92aWRlLiJ9",
        "specificationVersion": "2.2.0"
    }
}

PROPERTYTYPEDESCRIPTIONPOSSIBLE VALUES
secureServiceStringService used to authenticate the transaction
secureIdStringThe secureId you get from the token response
securityObjectThe security object received from the token response
security.acsURLStringURL of the challenge page of the issuer
security.authenticationTransactionIdStringID of the transaction verified by the brands.
security.specificationVersionString3D Secure version. Must be greater than 2.0
security.paReqStringThis parameter contains zipped Based64-encoded data on the transaction. This parameter is received from the brands.
security.authRequiredBooleanIdentifies whether the 3DS challenge is required or not.

requestSecureValidation()#

It is necessary to validate that the 3DS flow has been completed successfully and that the 3DS challenge has been successfully passed. To do this, the requestSecureValidation() method must be used, sending the secureId parameter obtained from the requestToken() method.


Response
The response object must have the following structure, to complete the valid 3DS flow.

{
    "code": "3DS000",
    "message": "ok"
}

Example


d6d065f2-6e08-4729-953f-d4df9b3bc1ad.gif

getBinInfo()#

Returns an object with the information related to the credit card bin (first eight digits). For Chilean merchants, the response is helpful to decide whether to continue with the request of a card token (when cardType is CREDIT), or with the request of a card async token (when cardType is DEBIT):
Request


Required

PropertyTypeDescription
binStringThe first eight digits of the credit card


Recurring Charges Examples#

πŸ’³ Card Subscription
⏳ Async Subscription πŸ‡¨πŸ‡±

requestSubscriptionToken()#

To request a recurring charge token.
Required Parameters
PropertyTypeDescription
cardObjectThe card data collected in a card object.

Payouts Examples#

πŸ’Έ Cash Out πŸ‡¨πŸ‡΄

requestCashOutToken()#

To request a Cash Out token.
Required Parameters
PropertyTypeDescriptionPossible Values
nameStringName of the client
lastNameStringLast name of the client
documentTypeStringType of document that the client is using to pay.CC, NIT, CE, TI, PP
identificationStringDocument number that the client is using to pay
totalAmountNumberThe amount you are going to collect as a number
currencyStringCode of currency usedCOP

🚦 Handling Responses#

Once the execution finishes, you need to handle the Transaction object.
Successful Results
The onPostExecute method will receive a Transaction object. If the operation was successful, the token will be available by invoking the getToken method:
Failed Results & Exceptions
If the transaction was not successful, you can retrieve the error details directly from the object:
Error Code: Invoke transaction.getCode()
Description: Invoke transaction.getMessage()
Note: For any unexpected errors, the requestToken method will throw a managed exception of type KushkiException.

🎨 Sensory Branding#

The Card Branding Animation gives users meaningful confirmation of their payment.
Apply this animation only when the user has selected a Mastercard or Visa card to make payment, and play it after a transaction is complete.
Visa
Mastercard
Gradle Setup
Add the following dependencies in your build.gradle file:
Define the view ViewVisaAnimation in the target activity.

Properties#


PropertyTypeRequiredDescriptionDefaultPossible values
backdropColorAndroid colorNoSet a color for the animation background. See Android resource types for more information.white
languageCodeenumNoDefine the language of animation.ENGLISHENGLISH, SPANISH, PORTUGUESE
soundEnabledbooleanNoEnable or disable animation sound.truetrue, false
hapticEnabledbooleanNoEnable or disable animation haptics.truetrue, false
checkmarkModeenumNoShow check mark.CHECKMARKCHECKMARK, CHECKMARK_WITH_TEXT, NONE
checkmarkTextenumNoSet check mark text.APPROVEAPPROVE, COMPLETE, SUCCESS

Get visaAnimationView by the defined activity id:

Also you can define custom properties for the animation:
Finally, trigger the animation:

Properties#

PropertyTypeRequiredDescription
fnOnFinishedAnimationlambdaYesLambda to execute when animation finished.

Next Steps#

Remember that to continue with the payment flow you must send to your back-end the token received.
To start the charge process, please go to our backend integrations: Kushki Libraries or Kushki API


πŸ“– Reference Summary#

Find the methods available in our Android library. You can perform the following operations:
One-time Payment:
Create a Card token
Get Bin Info
Create a Card Async Token
Create a Transfer In token
Create a Cash In token
Recurring Charges
Create a Card recurring charge token
Get an Async Card recurring charge
Get a list of banks available for Recurring Charges With Wire Transfer Debit
Create a Transfer recurring charge token
Start and answer a challenge to validate the account data in Transfer Recurring Charges
Payouts
Create a Cash Out token

One-time Payment#


NameParametersReturnsDescription
requestToken()card, totalAmount, context, activityObjectReturns a token
requestSecureValidation()On the first call: secureService, secureServiceId, cityCode, stateCode, phone, expeditionDocumentDate. On second call: secureService, secureServiceId, questionnaireCode, answers (JSON Object)ObjectOn the first call, returns a questionnaire for the challenge. On second call, returns a code and a message with the results of the account verification
getBinInfo()binObjectReturns an object with the information related to the credit card bin
requestCardAsyncToken()totalAmount, returnUrl, email, descriptionObjectReturns a card async token
requestTransferToken()amount, callbackUrl, documentType, documentNumber, email, paymentDescription, userTypeObjectReturns a transfer in token
requestCashToken()totalAmount, currency, identification, documentType, name, lastName, email, descriptionObjectReturns a cash in token that can later be used to initialize a cash in transaction

Recurring Charges#


NameParametersReturnsDescription
requestSubscriptionToken()cardObjectReturns a recurring charge token
requestCardSubscriptionAsyncTokencurrency, email, cardNumber, callbackUrlObjectReturns an async card recurring charge token
getBankList()ObjectReturns a list of banks available for transfer Recurring Charges
requestTransferSubscriptionToken()documentNumber, bankCode, name, lastName, accountNumber, documentType, accountType, email, currencyObjectReturns a token along with a secureId, and secureService. The token can later be used to create a transfer recurring charge. Before that, you will need to confirm the account data by starting and answering a challenge with the secure validation method

Payouts#


NameParametersReturnsDescription
requestCashOutToken()totalAmount, currency, identification, documentType, name, lastName, email, descriptionObjectReturns a cash out token that can later be used to initialize a cash out transaction

πŸš€ Example Application#

You can find an example application in our GitHub android project repository.
Got a suggestion on this documentation? Contact Us.
Modified atΒ 2026-03-09 19:19:59
Previous
Kushki iOS ο£Ώ
Next
Kushki.js 🌐
Built with