Validación de registros completosBETAcore beta

Validá una entidad completa (tax_id, account, email, phone, name, address) por campo, chequeá consistencia y resumí readiness (payment, billing). Hasta 500 records por request.

Contrato estable; cambios breaking solo con deprecation previo.

POST/v1/validate/records
Resumen

Validate a batch of complete records (suppliers, customers). Each item declares its `country` (required) and any subset of fields: `tax_id`, `account` (+ optional `account_type`), `email`, `phone`, `name`, `address`. Every present field is validated with its own normalizer (reusing the per-field logic — no checksum reimplemented). The response adds `consistency[]` checks between fields and against the declared country (country↔tax_id, country↔account) and `readiness` per business process: `payment` (ready to pay) and `billing` (ready to invoice). Up to 500 records per request.

URL base: https://api.normadata.io

Header de autenticación: X-API-Key: nd-...

Cuerpo del request

Cuerpo del request

CampoTipoObligatorioDescripción
itemsarrayArray of records to validate (1–500). Each item is the object described below.
items[].reference_idstringnoClient-provided correlation id, echoed back verbatim in the matching result.
items[].countrystringISO 3166-1 alpha-2 country code. Used for per-field validation and consistency checks.
items[].tax_idstringnoTax / national ID. Type is resolved within the country.
items[].accountstringnoBank account number (CBU, CVU, CLABE, CCI, IBAN).
items[].account_typestringnoAccount type ∈ {cbu, cvu, clabe, cci, iban}. If omitted, detected from country + format.
items[].emailstringnoEmail address.
items[].phonestringnoPhone number (parsed using country as region).
items[].namestringnoFull person name (smart split into first / paternal surname).
items[].addressstringnoFree-form postal address.
Ejemplo de request

Ejemplo de request

cURL
curl -X POST https://api.normadata.io/v1/validate/records \
  -H "X-API-Key: nd_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" \
  -H "Content-Type: application/json" \
  -d '{"items":[
    {"reference_id":"prov-001","country":"AR",
     "tax_id":"20-12345678-6","account":"0170010600000123456780","account_type":"cbu",
     "name":"Juan Pérez","email":"juan@empresa.com"}
  ]}'
Go
package main

import (
	"bytes"
	"encoding/json"
	"fmt"
	"net/http"
	"os"
)

type RecordItem struct {
	ReferenceID string `json:"reference_id"`
	Country     string `json:"country"`
	TaxID       string `json:"tax_id,omitempty"`
	Account     string `json:"account,omitempty"`
	AccountType string `json:"account_type,omitempty"`
	Name        string `json:"name,omitempty"`
	Email       string `json:"email,omitempty"`
}

type ReadinessFlag struct {
	Status string `json:"status"`
	Reason string `json:"reason,omitempty"`
}

type RecordResult struct {
	ReferenceID string `json:"reference_id"`
	Country     string `json:"country"`
	Readiness   struct {
		Payment ReadinessFlag `json:"payment"`
		Billing ReadinessFlag `json:"billing"`
	} `json:"readiness"`
}

type RecordResponse struct {
	Results []RecordResult `json:"results"`
}

func main() {
	body, _ := json.Marshal(map[string][]RecordItem{
		"items": {
			{
				ReferenceID: "prov-001",
				Country:     "AR",
				TaxID:       "20-12345678-6",
				Account:     "0170010600000123456780",
				AccountType: "cbu",
				Name:        "Juan Pérez",
				Email:       "juan@empresa.com",
			},
		},
	})
	req, _ := http.NewRequest("POST", "https://api.normadata.io/v1/validate/records", bytes.NewReader(body))
	req.Header.Set("X-API-Key", os.Getenv("NORMADATA_API_KEY"))
	req.Header.Set("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)
	defer res.Body.Close()

	var out RecordResponse
	json.NewDecoder(res.Body).Decode(&out)
	for _, r := range out.Results {
		fmt.Println(r.ReferenceID, r.Readiness.Payment.Status, r.Readiness.Billing.Status)
	}
}
Ejemplo de respuesta

Ejemplo de respuesta 200

JSON
{
  "results": [
    {
      "reference_id": "prov-001",
      "country": "AR",
      "fields": {
        "tax_id": { "valid": true, "normalized": "20123456786" },
        "account": { "valid": true, "checksum_valid": true, "bank_name": "Galicia", "country": "AR" },
        "name": { "full": "Juan Pérez", "first": "Juan", "paternal": "Pérez" },
        "email": { "valid": true, "normalized": "juan@empresa.com" }
      },
      "consistency": [
        { "check": "country_matches_tax_id", "ok": true },
        { "check": "country_matches_account", "ok": true }
      ],
      "readiness": {
        "payment": { "status": "ready" },
        "billing": { "status": "ready" }
      }
    }
  ]
}
Errores comunes

Errores comunes

Códigos de error que podés encontrar al llamar este endpoint. El envelope completo está documentado en la referencia principal.

Código
empty_batch
batch_too_large
quota_exceeded

Ver todos los códigos de error

Notas

Notas

Not KYC or identity verification, and no government lookups — it confirms the record is well-formed and internally consistent, not that the entity exists. `readiness` has only `payment` and `billing`. `payment.ready` ⟺ tax_id valid + account valid + checksum verified + country↔account consistent. `billing.ready` ⟺ tax_id valid + name present. The envelope is shared by every endpoint: POST `{items:[…]}` (1–500 for records) → `{results:[…]}` correlated by `reference_id`.

Acceso

Usá este endpoint en acceso anticipado

El acceso a Normadata es por solicitud. Solicitá acceso con tu caso de uso y provisionamos la API key para tu cuenta.

Solicitar acceso