Skip to main content

Standards

To facilitate integration and ensure information integrity, a set of standards has been defined and is followed throughout the API.

Monetary Values

Examples:

10000
12345
98741
1223
1
0

The APIs assume that all monetary values sent are in Brazilian Reais (BRL). Values must be sent as integers in cents.

Date and Time with Timezone

Examples:

2019-10-15T22:35:12.232-03:00
2018-05-01T13:32:11.297+00:00
2019-05-01T00:00:00.000+00:00

Represented according to ISO 8601. In this case, the timezone is placed immediately after the time and should represent the offset of the location where that data is valid.

The mask used for validation is as follows:

YYYY-MM-ddThh:mm:ss.sss±hh:mm

Date and Time without Timezone

Examples:

2019-10-15T22:35:12
2018-05-01T13:32:11
2019-05-01T00:00:00

Represented according to ISO 8601. Data that is independent of a timezone should be sent without it, always in UTC, with the letter "Z" indicating that the data is in UTC. Therefore, the following format will be validated:

YYYY-MM-ddThh:mm:ss.sssZ

Data

Alguns exemplos

2019-10-15
2019-01-01
2017-03-20

For fields that receive only the date without any time information, it must be sent in the following format:

YYYY-MM-dd

Documents

Since document numbers vary significantly and many contain non-numeric characters, all document numbers are defined as strings. Another reason to define them as strings is to prevent leading zeros from disappearing. Documents specified on this page have a well-defined mask and are subject to validation. Other documents, such as RG (Identity Card), will not be validated due to their lack of standardization.

CPF

Examples of valid CPFs against the defined mask:

123.456.789-12
321.987.543-23
111.283.333-00

Examples of invalid CPFs against the defined mask:

8.577.477-8
08.104.627/0001-23
123.456.789-1
23.456.789-01

The CPF is always defined as a string and will be validated against the mask:

###.###.###-##

CNPJ

Examples of invalid CNPJs against the defined mask:

08.104.627/0001-02
01.079.210/0114-67
32.402.502/0001-35

Examples of invalid CNPJs against the defined mask:

8.577.477-8
123.456.789-12
321.987.543-23
32.402.502/0001-3
032.402.502/0001-3

The CNPJ is always defined as a string and will be validated against the mask:

##.###.###/####-##

IP Address

Examples of valid IPs against the defined mask:

201.81.161.86
201.081.161.86
201.81.161.086
201.81.0.1

Examples of invalid IPs:

201.81..86
358.81.161.86
201.81.161

IP addresses must always be sent in IPv4 format. Leading zeros are optional and must follow this mask:

###.###.###.###