Pre-validate KYC address
Optional early check for the address step of a Tier 4 (end-user identity)
registration: validates a postal address for deliverability BEFORE the full
KYC submit, so it can be corrected before any documents are uploaded. The
full submit (POST /v1/whatsapp/phone-numbers/kyc) re-validates the address,
so this call is purely a fast feedback path and skipping it is safe. Only
the postal address is sent (no documents, no gov-ID fields). A region
(administrative_area) is required by the validator; when it is omitted the
pre-check is skipped and { ok: true, skipped: true } is returned (the
final submit still validates).
API key authentication - use your Zernio API key as a Bearer token
In: header
ISO 3166-1 alpha-2 country code.
2 <= length <= 2City / town.
State / province / region. When omitted, the pre-check is skipped (the final submit still validates).
Response Body
application/json
application/json
application/json
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.whatsappphonenumbers.validateWhatsAppNumberKycAddress({ body: { country: 'string', street_address: 'string', locality: 'string', postal_code: 'string', },});console.log(data);{
"ok": true,
"skipped": true
}{
"error": "string",
"type": "string",
"code": "INVALID_FIELD_VALUE",
"param": "address",
"details": {
"addressSuggestions": [
{
"field": "administrative_area",
"label": "State / Province",
"value": "Dublin"
}
]
}
}{
"error": "Unauthorized"
}Upload a KYC document POST
Upload ONE document and get back its provider document id, to reference from POST /v1/whatsapp/phone-numbers/kyc via `documents[].documentId`. Send the RAW file bytes as the request body (not base64); put the filename in the `X-Filename` header. Uploading documents one-per-request keeps each request under the ~4.5MB body limit. The document streams straight to the number provider and is not stored by Zernio.
Create a hosted KYC link POST
Create a single-use, 7-day hosted KYC link that your end customer completes WITHOUT a Zernio login — useful when the person who holds the ID and address is not your team. They fill the regulated verification on a Zernio-hosted page; the number provisions under YOUR account once they submit. Only regulated (KYC) countries are valid: a country that does not require KYC returns 400. White-label the page with `branding` (your company name, logo, brand color). Supply `redirect_url` to send the end customer back to your own site after a successful submit (completion params are appended — see below). Listen for the `whatsapp.number.kyc_submitted` webhook to react when the form is completed.