2.1 Create Pix Key

PIX Key Creation and Registration

PIX keys created via API are registered within the Central Bank’s Transactional Account Identifier Directory (DICT). Once validated, the PIX key is linked to the requested account and will be ready to be used.

Creating PIX Keys

API Method = CreatePixKey

The key being registered must be created under the parameter Key, following the PIX Key types as seen below:

  • CPF: 0
  • CNPJ: 1
  • E-mail: 2
  • Cell Phone: 3
  • Random Key: 4 or null

Important: In order to create a cell phone key successfully, this format must be followed:

  • +55 00 0 0000 0000

A correct cell phone key must contain the country's DDI, the state/unit's DDD and then the actual phone number's digits. The spaces between the numbers shown above are merely to demonstrate the different components of the number, when inputting for actual use the digits must be entered all together.

{    
	"Method": "CreatePixKey",
	"PartnerId": 123,
	"BusinessUnitId" : 123,
	"PixKey": "12345678901",
	"TaxNumber": "12345678901",
	"PixKeyType": 0,
	"Bank": "001",
	"BankBranch": "1234",
	"BankAccount": "123456",
	"BankAccountDigit": "1"
}
{
    "Success": "true",
    "Message": "Solicitação para registro de chave do tipo Celular recebida com sucesso.",
    "Key": "+5588996111111",
    "DocumentNumber": 220624
}
{
    "Success": "true",
    "Message": "Solicitação para registro de chave do tipo Aleatória recebida com sucesso.",
    "Key": null,
    "DocumentNumber": 22063
}
{
    "Success": "true",
    "Message": "Solicitação para registro de chave do tipo E-mail recebida com sucesso.",
    "Key": "[email protected]",
    "DocumentNumber": 22064
}
{
    "Success": "true",
    "Message": "Solicitação para registro de chave do tipo CPF recebida com sucesso.",
    "Key": "50231669020",
    "DocumentNumber": 22065
}

Description:

FieldDescriptionMandatoryType
MethodMethod to be usedYESSTRING
PartnerIdInformation provided by FitBankYESINT
BusinessUnitIdInformation provided by FitBankYESINT
PixKeyKey to be registeredYESSTRING
TaxNumberCPF/CNPJ of who will have the PIX keyYESSTRING
PixKeyTypeSocialSecurity = 0 TaxNumber = 1 E-mail = 2 PhoneNumber = 3 RandomKeyCode = 4 or nullYESINT
BankBank Code (Ex.: “450”)YESSTRING
BankBranchBank Agency Code (Ex.: “0001”)YESSTRING
BankAccountBank Account (Ex.: “146492”)YESSTRING
BankAccountDigitBank Account Digit (Ex.: “1")YESSTRING

Confirmation of the PIX key: E-mail or Phone Number

ConfirmPixKeyHold

API Method = ConfirmPixKeyHold

In this case, it is necessary to ensure that the e-mail or cell phone being registered as a PIX key belongs to the requesting user. This validation is done by a numeric token sent to the user via e-mail or SMS, depending on the PIX key type requested.

In this method, it is necessary to specify the bank details of the account for which the user wants to register the key, when confirming its ownership.

The token must be received by the user and entered in the ConfirmationCode field.

{
	"Method": "ConfirmPixKeyHold",                                         
	"PartnerId": 1,                                                                                                          
	"BusinessUnitId": 1,                                                                                                                                                                        
	"PixKey": "12345678912",                                                                                                                                                            
	"PixKeyType": 0,
	"TaxNumber": "12345678912",
	"ConfirmationCode": "13216",
	"Bank": "450",
	"BankBranch": "0001",
	"BankAccount": "00110",
	"BankAccountDigit": "3"
}

Description:

FieldDescriptionMandatoryTipo
MethodMethod to be usedYESSTRING
PartnerIdInformation provided by FitBankYESINT
BusinessUnitIdInformation provided by FitBankYESINT
PixKeyPIX key valueYESSTRING
PixKeyTypeE-mail = 2 PhoneNumber = 3YESINT
TaxNumberCPF/CNPJ of who will be the PIX key ownerYESSTRING
ConfirmationCodeConfirmation CodeYESSTRING
BankBank Code (Ex.: "450")YESSTRING
BankBranchBank Agency Code (Ex.: "0001")YESSTRING
BankAccountBank Account (Ex.: "146492")YESSTRING
BankAccountDigitBank Account Digit (Ex.: "1")YESSTRING

If the token has not been received or expired, use the ResendPixKeyToken method to resend the token and then use ConfirmPixKeyHold method again.

Resend PIX Key Token

ResendPixKeyToken

API Method = ResendPixKeyToken

If the token has not been received or expired, use the ResendPixKeyToken method and use ConfirmPixKeyHold again.

{
  "Method": "ResendPixKeyToken",
  "PartnerId": 693,
  "BusinessUnitId": 494,
  "PixKey": "[email protected]",
  "TaxNumber": "75412107060",
  "PixKeyType": 2,
  "Bank": "450",
  "BankBranch": "0001",
  "BankAccount": "00110",
  "BankAccountDigit": "3"
}

Description:

FieldDescriptionMandatoryType
MethodMethod to be usedYESSTRING
PartnerIdInformation provided by FitBankYESINT
BusinessUnitIdInformation provided by FitBankYESINT
PixKeyPIX keyYESSTRING
PixKeyTypeE-mail = 2 PhoneNumber = 3YESINT
TaxNumberCPF/CNPJ of who will have the PIX keyYESSTRING
BankBank Code (Ex.: "450")YESSTRING
BankBranchBank Agency Code (Ex.: "0001")YESSTRING
BankAccountBank Account (Ex.: "146492")YESSTRING
BankAccountDigitBank Account Digit (Ex.: "1")YESSTRING