Fiskaly Validate TIN
Description
Section titled “Description”This module allows validating a tax identification number (TIN - Tax Identification Number) using the Fiskaly API. It accepts Spanish NIF, CIF and NIE formats, as well as tax numbers from other countries by configuring the country_code.
Validation is performed via a POST to the Fiskaly API that verifies the structure and validity of the provided tax number. The result indicates whether the number is valid or not, along with additional details.
The module is of type hidden (hidden in the main interface).
Configuration
Section titled “Configuration”| Parameter | Type | Required | Description |
|---|---|---|---|
| credentials_id | credentials | Yes | Fiskaly credential |
| tin | text | Yes | Tax identification number to validate (NIF/CIF/NIE) |
| country_code | text | No | ISO country code (default: ES) |
Credentials
Section titled “Credentials”Requires Fiskaly type credentials with:
- api_key: Fiskaly API Key
- api_secret: Fiskaly API Secret
Output
Section titled “Output”{ "nextModule": "siguiente_modulo", "data": { "success": true, "valid": true, "tin": "B12345678", "details": { "...detalles de la validacion..." }, "message": "NIF/CIF B12345678 es valido" }}If not valid:
{ "nextModule": "siguiente_modulo", "data": { "success": true, "valid": false, "tin": "XINVALIDO", "details": { "...detalles del error..." }, "message": "NIF/CIF XINVALIDO no es valido" }}Usage Example
Section titled “Usage Example”Basic case
Section titled “Basic case”{ "credentials_id": "mi-fiskaly", "tin": "B12345678", "country_code": "ES"}API Used
Section titled “API Used”- Fiskaly SIGN ES API - POST
/validation/tin
- The default country code is ES (Spain)
- Supports NIF (individuals), CIF (legal entities) and NIE (foreigners)
- Useful as a preliminary step before creating a taxpayer or client to ensure correct data
- A
valid: trueresult does not guarantee that the NIF is active with the AEAT, it only validates the format
Related Nodes
Section titled “Related Nodes”- FiskalyUpsertTaxpayer - Create/update taxpayer
- FiskalyUpsertClient - Create/update device