Pagsmile
Introduction
Pagsmile is a service that allows payments by card or through the alternative payment methods PIX, Loterica and Boleto. It also allows PIX Payouts and Bank Transfer Payouts. It can be used both in Paylands checkout and via redirection, as well as with push payments.
Extra data required
Pagsmile expects to receive the following information in the extra_data
field when creating the order. The fields to send vary depending on the payment method chosen.
"extra_data": {
"profile": {
"first_name": "John",
"last_name": "Doe",
"email": "johndoe@paynopain.com"
"document_identification_number": "11032341882",
"phone": {
"number": "700000000",
"prefix": "351"
}
},
"billing_address": {
"address1": "calle test",
"city": "",
"state_code": "",
"zip_code": "38082365",
"country": "BRL"
}
}
- Payment card: no
extra_data
needed - PIX: name, email and document identification number (CPF)
- Loterica: name, email and document identification number (CPF) and phone number
- Boleto: name, email, document identification number (CPF) and postal code (
zip_code
)
Payouts
Pagsmile allows payouts in different countries using the following payment methods:
Brazil
PIX Payout
Required fields:
- First name and last name (
profile.first_name
andprofile.last_name
) - Identification document number (CPF) (
profile.document_identification_number
)
PIX payouts will be performed using CPF as the default account type. If you wish to use another type of account, this must be indicated when creating the order, by sending the field extra_data.payment.account_type
, together with the associated field for each type, where the value of the corresponding account must be indicated:
Account type | Account | Description | Example |
---|---|---|---|
CPF | extra_data.profile.document_identification_number | CPF. 11 dígits. | 22*******99 |
PHONE | extra_data.profile.phone.number | Telephone number, without telephone prefix. | 11987654321 |
extra_data.profile.email | Email. | merchant@pagsmile.com | |
EVP | extra_data.payment.evp | 32-character alphanumeric key, which is associated with a bank account. | a1073db4-a3a0-11ed-a8fc-0242ac120002 |
The following example shows the extra_data
sent on order creation for a PIX payout, using EMAIL
as the account type:
"extra_data": {
"profile": {
"first_name": "John",
"last_name": "Doe",
"email": "merchant@pagsmile.com",
"document_identification_number": "842.359.516-10"
},
"payment": {
"account_type": "EMAIL"
}
}
Bank Transfer Payout Brazil (Transfer)
Required fields:
- First and last name (
profile.first_name
andprofile.last_name
) - Identification document number (CPF) (
profile.document_identification_number
) - Bank code (
payment.bank_code
) See Brazilian bank codes - Branch (
payment.branch
) - Account number (
payment.account
) - Account type (
payment.account_type
): valuesSAVINGS
orCHECKING
.
In the case of Bank Transfer Payouts it will also be necessary to send the bank account information in the payment
field:
"extra_data": {
"profile": {
"first_name": "John",
"last_name": "Doe",
"document_identification_number": "842.359.516-10"
},
"payment": {
"bank_code": "001",
"branch": "0002",
"account": "123412341",
"account_type": "CHECKING"
}
}
Colombia
Tpaga
Required fields:
- First and last name (
profile.first_name
andprofile.last_name
) - Country (
billing_address.country
): fixed valueCOL
- Telephone number (
profile.phone.number
) - Account type (
payment.account_type
): fixed valuePHONE
"extra_data": {
"profile": {
"first_name": "Victor",
"last_name": "lastname",
"phone": {
"number": "322222222"
}
},
"billing_address": {
"address1": "test street",
"city": "",
"state_code": "",
"zip_code": "",
"country": "COL"
},
"payment": {
"account_type": "PHONE"
}
}
Transfiya
Transfiya payments require amount
>= 1000 COP.
Required fields:
- First and last name (
profile.first_name
andprofile.last_name
) - Identification document number (
profile.document_identification_number
) - Identification document type (
profile.document_identification_type
) See identification document types. - Country (
billing_address.country
): fixed valueCOL
. - Phone number (
profile.phone.number
) - Account type (
payment.account_type
): fixed valuePHONE
"extra_data": {
"profile": {
"first_name": "Victor",
"last_name": "lastname",
"document_identification_number": "123456789",
"phone": {
"number": "572222222222"
}
},
"billing_address": {
"address1": "test street",
"city": "",
"state_code": "",
"zip_code": "",
"country": "COL"
},
"payment": {
"account_type": "PHONE"
}
}
Bank Transfer Payout Colombia (Transfer)
Required fields:
- First and last name (
profile.first_name
andprofile.last_name
) - Identification document number (
profile.document_identification_number
) - Identification document type (
profile.document_identification_type
) See identification document types. - Country (
billing_address.country
): fixed valueCOL
- Bank code (
payment.bank_code
) See Colombian bank codes - Account number (
payment.account
) - Account type (
payment.account_type
): valuesSAVINGS
orCHECKING
.
"extra_data": {
"profile": {
"first_name": "Victor",
"last_name": "lastname",
"email": "test@pagsmile.com",
"document_identification_number": "123456789",
"phone": {
"number": "012345678910"
}
},
"billing_address": {
"address1": "test street",
"city": "",
"state_code": "",
"zip_code": "",
"country": "COL"
},
"payment": {
"bank_code": "007",
"account": "57012345678910",
"account_type": "CHECKING"
}
}
Chile
Vita Wallet
Vita Wallet payments require amount
>= 5000 CLP.
Required fields:
- First name and last name (
profile.first_name
andprofile.last_name
) - Country (
billing_address.country
): fixed valueCHL
. - Phone number (
profile.email
) - Account type (
payment.account_type
): fixed valueEMAIL
"extra_data": {
"profile": {
"first_name": "Victor",
"last_name": "lastname",
"email": "paid@pagsmile.com"
},
"billing_address": {
"address1": "test street",
"city": "",
"state_code": "",
"zip_code": "",
"country": "CHL"
},
"payment": {
"account_type": "EMAIL"
}
}
Bank Transfer Payout Chile (Transfer)
Required fields:
- First and last name (
profile.first_name
andprofile.last_name
) - Identification document number (
profile.document_identification_number
) - Identification document type (
profile.document_identification_type
) See identification document types. - Country (
billing_address.country
): fixed valueCHL
- Bank code (
payment.bank_code
) See Chilean bank codes - Account number (
payment.account
) - Account type (
payment.account_type
): valuesSAVINGS
orCHECKING
.
"extra_data": {
"profile": {
"first_name": "Victor",
"last_name": "lastname",
"document_identification_number": "111111111"
},
"billing_address": {
"address1": "test street",
"city": "",
"state_code": "",
"zip_code": "",
"country": "CHL"
},
"payment": {
"account_type": "CHECKING",
"account": "222222222222",
"bank_code": "001"
}
}
Mexico
SPEI Payout
Required fields:
- First name and last name (
profile.first_name
andprofile.last_name
) - Identification document number (
profile.document_identification_number
) - Identification document type (
profile.document_identification_type
) See identification document types. - Country (
billing_address.country
): fixed valueMEX
- Account type (
payment.account_type
): valuesDEBIT
,PHONE
orCLABE
. - Account number (
payment.account
) Required ifaccount_type
is different fromPHONE
. - Phone number (
profile.phone.number
) Required only ifaccount_type
isPHONE
. - Bank code (
payment.bank_code
). Required ifpayment.account_type
is different from CLABE. See Mexican bank codes
"extra_data": {
"profile": {
"first_name": "Victor",
"last_name": "lastname",
"document_identification_number": "111111111"
},
"billing_address": {
"address1": "test street",
"city": "",
"state_code": "",
"zip_code": "",
"country": "MEX"
},
"payment": {
"account_type": "CLABE",
"account": "646020146401877826"
}
}
Type of identification document
The type of identification document must be indicated within the extra_data
in the field profile.document_identification_type
. By default, if not specified, the value NATIONAL_IDENTITY_DOCUMENT will be used.
The possible values of this field and their equivalences for the different types of documents for each country are shown below:
Brazil | Colombia | Chile | Mexico | |
---|---|---|---|---|
NATIONAL_IDENTITY_DOCUMENT | CPF | CC | RUN | CURP |
FOREIGN_IDENTIFICATION_DOCUMENT | - | CE | CE | - |
FISCAL_IDENTIFICATION_CODE | - | - | RUT | RFC |
VALID_PASSPORT | - | - | PAS | - |
Payment methods in Sandbox
The test card is as follows. In general, the expiration date and CVV do not matter as long as the date is after the current date, and the CVV has 3 digits.
- card number: 4111 1111 1111 1111 1111 1111
- CVV: 123
- expiration date: 12/34
Currency
The currencies supported for this service are Brazilian Real (BRL), Colombian Peso (COP), Chilean Peso (CLP) and Mexican Peso (MXN).
Error codes
The error structure is as follows:
Code - Message
For example:
4001001 - invalid document_id