Skip to main content
POST
https://api.json.pe/api
/
dni-ruc
cURL
curl --request POST \
  --url https://api.json.pe/api/dni-ruc \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "dni": "12345678"
}
'
{
  "success": true,
  "message": "El DNI si cuenta con RUC",
  "data": {
    "ruc": "10123456781"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.json.pe/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

DNI de 8 dígitos a consultar

Request body para consulta DNI - RUC. El DNI debe ser un string de 8 dígitos.

dni
string
required

Número de DNI de 8 dígitos

Required string length: 8
Pattern: ^[0-9]{8}$
Example:

"12345678"

Response

Consulta exitosa. Retorna el RUC asociado al DNI.

success
boolean

El estado de la respuesta true o false

message
string

Mensaje de la respuesta

data
object

Datos del RUC asociado al DNI