Serverless application to fetch CNPJ data from Casa dos Dados.
Get data without any filter.
curl https://cnpj.rafaelfranco.com
Allow filter body
to be sent with the request. See body format below.
curl --location --request POST 'https://cnpj.rafaelfranco.com' \
--header 'Content-Type: application/json' \
--data-raw '{
"page": 2
}'
A default body is included with the request, and can be changed here.
{
"query": {
"termo": [],
"atividade_principal": [],
"natureza_juridica": [],
"uf": [],
"municipio": [],
"situacao_cadastral": "ATIVA",
"cep": [],
"ddd": []
},
"range_query": {
"data_abertura": {
"lte": null,
"gte": null
},
"capital_social": {
"lte": null,
"gte": null
}
},
"extras": {
"somente_mei": false,
"excluir_mei": false,
"com_email": false,
"incluir_atividade_secundaria": false,
"com_contato_telefonico": false,
"somente_fixo": false,
"somente_celular": false,
"somente_matriz": false,
"somente_filial": false
},
"page": 1
}
This is the exact body that Casa dos Dados sends in its request, so you can just tweak it for your liking.