Skip to content

/pix/key/register Register Pix Key ​

Background ​

/pix/key/register binds a Pix Key of the specified type to a merchant bank account. The endpoint is shared by merchants and partners.

Pix Key types support PHONE, EMAIL, CPF, CNPJ, and EVP. The PHONE and EMAIL types require a key; the CPF and CNPJ types do not need a key — the system registers the key from the merchant's registered tax ID; an EVP key is generated by the system, and key is not sent in the request. Before registering a mobile number or email Pix Key, call the Send Verification Code endpoint first, fill the verification code into token, and fill the data.verificationRequestId from its response into verificationRequestId.

Endpoint ​

ItemValue
MethodPOST
Path/pix/key/register
Content-Typeapplication/json
PurposeRegister a Pix Key for a merchant bank account

Access Requirements ​

Request Fields ​

FieldLocationTypeMax LengthRequiredDescription
X-Merchant-IdHeaderstring64YesMerchant ID of the integrator; partners use the primary merchant ID.
X-TimestampHeaderint19YesUnix request timestamp in seconds, used to validate request freshness.
X-NonceHeaderstring64YesAnti-replay random string for the request.
DigestHeaderstring52YesDigest of the request body, in the format SHA-256=<Base64 digest>.
AuthorizationHeaderstringVariableYesES256 request signature information, where keyId is the integrator's key version number.
keyBodystring64ConditionalPix Key value. Required for the PHONE and EMAIL types; the CPF and CNPJ types do not need a key (registered from the merchant's tax ID); omitted for the EVP type. For mobile numbers, use the international format with the country code, for example the Brazilian mobile number +5511999999999.
keyTypeBodystring10YesPix Key type: PHONE for mobile number, EMAIL for email, CPF for the Brazilian personal tax ID, CNPJ for the Brazilian business tax ID, and EVP for a system-generated random key.
tokenBodystring6ConditionalThe 6-digit verification code received by the mobile number or email Pix Key; required for the PHONE and EMAIL types, omitted for the other types.
verificationRequestIdBodystring64ConditionalVerification request ID, 64 characters long, taken from data.verificationRequestId in the response of the Send Verification Code endpoint; required for the PHONE and EMAIL types, omitted for the other types.

Request Example ​

http
POST /pix/key/register HTTP/1.1
Content-Type: application/json
X-Merchant-Id: 92315566000120
X-Timestamp: 1786867200
X-Nonce: 550e8400-e29b-41d4-a716-446655440000
Digest: SHA-256=<Base64 digest>
Authorization: Signature keyId="v1",alg="ES256",headers="(request-target) x-timestamp x-nonce digest",signature="<ES256_SIGNATURE_BASE64>"

{
  "key": "financeiro@example.com",
  "keyType": "EMAIL",
  "token": "123456",
  "verificationRequestId": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef"
}

Response Fields ​

The endpoint uses the standard status, msg, and data response structure.

FieldTypeMax LengthAlways ReturnedDescription
statusint4YesResponse code
msgstring128YesCorresponds to status
dataobjectN/ANoPix Key registration result; it may be omitted when the request fails at the signature verification or protocol parsing stage.
data.keystring64YesThe Pix Key after successful registration; for the EVP type, returns the system-generated random key.
data.keyTypestring10YesThe registered Pix Key type: PHONE for mobile number, EMAIL for email, CPF for the Brazilian personal tax ID, CNPJ for the Brazilian business tax ID, and EVP for a system-generated random key.

Response Example ​

json
{
  "status": 200,
  "msg": "sucesso",
  "data": {
    "key": "financeiro@example.com",
    "keyType": "EMAIL"
  }
}

Response Error Codes ​