Saltar a contenido

Verificar Persona

Consulta información oficial del ciudadano asociada al número de documento.

POST /persona/verificar


Parámetros

Campo Tipo Obligatorio Ejemplo Descripción
documento string 32123456 DNI del paciente

Ejemplo de solicitud

curl

curl -X POST "https://api.asystir.com/v1/persona/verificar" \
  -H "X-API-Key: TU_API_KEY" \
  -H "X-API-Secret: TU_API_SECRET" \
  -H "Content-Type: application/json" \
  -d '{"documento": "32123456"}'

JavaScript (fetch)

fetch("https://api.asystir.com/v1/persona/verificar", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "X-API-Key": "TU_API_KEY",
    "X-API-Secret": "TU_API_SECRET"
  },
  body: JSON.stringify({ documento: "32123456" })
})
.then(r => r.json())
.then(console.log);

Visual Basic .NET

Dim client As New HttpClient()
client.DefaultRequestHeaders.Add("X-API-Key", "TU_API_KEY")
client.DefaultRequestHeaders.Add("X-API-Secret", "TU_API_SECRET")

Dim content As New StringContent("{""documento"":""32123456""}", Encoding.UTF8, "application/json")
Dim response = Await client.PostAsync("https://api.asystir.com/v1/persona/verificar", content)
Dim result = Await response.Content.ReadAsStringAsync()
Console.WriteLine(result)

Ejemplo de respuesta

{
  "success": true,
  "data": {
    "nombre": "Juan",
    "apellido": "Pérez",
    "edad": 41,
    "domicilio": "Av. Siempre Viva 742",
    "documento": "32123456"
  }
}

Errores Comunes

Código Causa
404 Documento no encontrado
400 Formato inválido