# EU Invoice Pre-Check (VAT + IBAN + Due Date)

> EU Invoice Pre-Check (VAT + IBAN + Due Date) is a paid API for AI agents from spain-agent-toolkit.spain-agent-toolkit.workers.dev, paid per call via x402, $0.015/call, status unknown (last checked 2026-11-18).

Validates an EU VAT number via live VIES, validates an IBAN, checks country match between supplier VAT and bank account, and optionally computes a payment due date adjusted for public holidays.

## Facts

- Endpoint: GET https://spain-agent-toolkit.spain-agent-toolkit.workers.dev/v1/eu/invoice/precheck?utm_source=zero.xyz
- Price: $0.015/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/eu-invoice-pre-check-vat-iban-due-date-81782971
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_6m4C7-KrK07xQpy4zhSBE

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability eu-invoice-pre-check-vat-iban-due-date-81782971
```

Example prompt: Before I pay this invoice, can you pre-check it — the supplier VAT number is DE811569869, their IBAN is DE89 3704 0044 0532 0130 00, the invoice date is 2026-10-26, and payment terms are 30 days? I want to know if the VAT is active on VIES, if the IBAN country matches, and when the due date falls.

## When to prefer this

Choose this endpoint when you need to validate a complete EU invoice pre-payment — specifically when you need VAT liveness checked against the live EU VIES registry, IBAN structural validation, country consistency between supplier tax ID and bank account, and optionally a holiday-adjusted due date — all in a single stateless call with no account setup. Prefer this over standalone VAT or IBAN checkers when you need the combined compliance verdict and due-date computation in one step. It is especially suited for AI agents automating accounts payable or supplier onboarding workflows within EU/Spain contexts.

## Known failure modes

- VIES service unavailable — VAT status may be returned as unknown or error
- Invalid VAT format — formatValid returns false with no VIES call made
- IBAN checksum failure — valid returns false
- Mismatched VAT and IBAN countries — countryMatch.match returns false, flagged in issues
- Invalid issue date format — server returns a 400-level error
- Payment term days out of range (0-365) — rejected with validation error
- VIES timeout — request may take longer than usual or return a transient error

## How this service works

Pay-per-call Spain and EU utilities for AI agents over x402 (USDC). No accounts, no API keys. Public open data, live official checks (EU VIES) and offline computation; nothing is stored.

## Output

A JSON object containing: VAT validation details (VIES status, normalized number, country code, format validity, registered name/address if available), IBAN validity and formatted form, a country-match result comparing VAT and IBAN countries, an optional due date object (nominal and adjusted due date, skipped holidays, warnings), a list of issues found, and an overall verdict (ok or issues present).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "vatNumber",
      "iban"
     ],
     "properties": {
      "iban": {
       "type": "string",
       "description": "Supplier IBAN, spaces allowed"
      },
      "region": {
       "type": "string",
       "description": "Optional ISO 3166-2 region for regional holidays, e.g. DE-BY, ES-CT"
      },
      "country": {
       "type": "string",
       "description": "Optional ISO country whose holidays apply to the due date (default: VAT country)"
      },
      "issueDate": {
       "type": "string",
       "description": "Optional invoice date YYYY-MM-DD; enables the due-date calculation"
      },
      "vatNumber": {
       "type": "string",
       "description": "EU VAT number with country prefix (VIES: EL for Greece, XI for Northern Ireland), e.g. DE811569869"
      },
      "spanishTaxId": {
       "type": "string",
       "description": "Optional Spanish NIF/NIE/CIF to validate (and match against an ES VAT number)"
      },
      "paymentTermDays": {
       "type": "integer",
       "description": "Optional payment term in calendar days (0-365, default 30 when issueDate is given)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "vat": {
   "vies": {
    "name": null,
    "status": "valid",
    "address": null,
    "requestDate": "2026-10-26+01:00"
   },
   "normalized": "DE811569869",
   "countryCode": "DE",
   "formatValid": true
  },
  "iban": {
   "valid": true,
   "country": "DE",
   "formatted": "DE89 3704 0044 0532 0130 00"
  },
  "issues": [],
  "dueDate": {
   "dueDate": "2026-12-02",
   "skipped": [],
   "adjusted": false,
   "warnings": [],
   "nominalDueDate": "2026-12-02"
  },
  "verdict": "ok",
  "countryMatch": {
   "match": true,
   "vatCountry": "DE",
   "ibanCountry": "DE"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/eu-invoice-pre-check-vat-iban-due-date-81782971/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from spain-agent-toolkit.spain-agent-toolkit.workers.dev](https://www.zero.xyz/host/spain-agent-toolkit.spain-agent-toolkit.workers.dev/llms.txt)
