Yape

Learn how to integrate your solution to process payments with Yape.

Yape

Yape, a widely embraced mobile payment system in Peru, offers a convenient way for individuals to conduct smartphone transactions. By seamlessly linking their bank accounts to the Yape app, customers can pay for products and services effortlessly.

Unlike other APMs in Peru, the Yape flow operates similarly to card transactions. However, instead of sharing card information, you need only provide the phone number and the authorization code generated by the customer in the Yape app.

Payment flow

The following diagram presents the payment flow used to pay with Yape.

PrintScreen

  1. The customer selects Yape as payment method.
  2. You must show the form to capture the mobile phone number and the authorization code.
  3. The customer opens Yape app and generates a new authorization code.
  4. The customer enters their mobile phone number and the authorization code previously generated.
  5. Bamboo process the transaction and returns a approved or rejected status.

Request parameters

You need to include specific fields for this payment method to work correctly. Check the Purchase operation article for details on authentication, languages of the response, and basic purchase parameters such as amount and currency.

PropertyTypeMandatory?Description
PaymentMethodstringYesFind the value in the table Payment Method.
TargetCountryISOstringYesIndicate the destination country.
CustomerEmailstringYesCustomer’s email.
CustomerFirstNamestringNoCustomer’s first name.
CustomerLastNamestringNoCustomer’s last name.
CustomerDocumentTypestringNoCustomer’s document type.
Refer to the Document types table to see the possible values.
CustomerDocumentNumberstringNoCustomer’s Document Number.
CustomerPhoneNumberstringNoCustomer’s phone number.
Max 9 characters.
CustomerAddressCountrystringNoCustomer’s Country.
CustomerAddressStatestringNoCustomer’s State.
CustomerAddressCitystringNoCustomer’s City.
CustomerAddressAddressDetailstringNoCustomer’s Address Detail.
CustomerAddressPostalCodestringNoCustomer’s Postal Code.
MetaDataInPaymentExpirationInMinutesnumericNoConfigure the expiration time for the payment using this field, specifying the duration in minutes. The API applies a default value if you don’t provide this information.
MetaDataInphoneNumbernumericYesMobile phone number of the Yape user.
MetaDataInotpnumericYesAuthorization code generated by the Yape user.

Request example

{
	"PaymentMethod": "YAP",
    "Order": "CH2023-001",
	"Amount": 100,
    "Currency": "PEN",
    "TargetCountryISO": "PE",
    "Customer": {
        "FirstName": "Joao",
        "LastName": "Silva",
        "ReferenceCode": "JS-001",
        "PhoneNumber":"936023105"
        "DocumentNumber": "12345678901",
        "DocumentType": "DNI.PE",
        "Email": "joao.silva@example.com",
        "Address": {
            "Country": "PE",
            "City": "Lima",
            "State": "SP",
            "PostalCode": "01310-200",
            "AddressDetail": "Avenida Paulista 1000"
        }
    },
	"MetaDataIn": {
        "PaymentExpirationInMinutes": "1440",
        "PhoneNumber": "936023105",
        "otp": "123456"
    }
}

Response parameters

For more information on the response parameters, please refer to the Response parameters section of the Purchase creation.

Response example

{
    "TransactionId": "79632697147789184",
    "Result": "COMPLETED",
    "Status": "APPROVED",
    "ErrorCode": null,
    "ErrorDescription": null,
    "Created": "2024-08-07T17:51:54.620",
    "AuthorizationDate": "2024-08-07T17:51:56.879",
    "AuthorizationCode": "839936",
    "Amount": 25000,
    "Currency": "PEN",
    "Installments": 1,
    "TaxableAmount": null,
    "Tip": null,
    "Url": "https://api.stage.bamboopayment.com/Purchase/79632697147789184",
    "MetadataIn": {
        "PaymentExpirationInMinutes": "1440",
        "phoneNumber": "969929157",
        "otp": "557454"
    },
    "Action": null,
    "PaymentMethod": {
        "Brand": "Yape",
        "CardOwner": null,
        "Bin": null,
        "IssuerBank": null,
        "Type": "BankTransfer",
        "Expiration": null,
        "Last4": null
    }
}
footer
Last modified January 20, 2025

© Bamboo | All rights reserved 2025