# EU Invoice Precheck Batch

> EU Invoice Precheck Batch is a paid API for AI agents from spain-agent-toolkit.spain-agent-toolkit.workers.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-11-20).

Validates a batch of up to 50 EU supplier invoices by checking VAT numbers against live VIES, validating IBANs, Spanish tax IDs, and computing payment due dates with holiday awareness.

## Facts

- Endpoint: GET https://spain-agent-toolkit.spain-agent-toolkit.workers.dev/v1/eu/invoice/precheck/batch?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-20
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/eu-invoice-precheck-batch-dd4a4a87
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_zrUaePbA4hSwz4LTtmKIt

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-precheck-batch-dd4a4a87
```

Example prompt: I have 3 supplier invoices to check before we process payment — can you batch-validate their EU VAT numbers and IBANs for me? Supplier 1: VAT DE811569869, IBAN DE89370400440532013000, issued 2024-06-01 with 30-day terms. Supplier 2: VAT ES12345678A, IBAN ES9121000418450200051332, region ES-CT. Supplier 3: VAT FR40303265045, IBAN FR7630006000011234567890189.

## When to prefer this

Choose this endpoint when you need to pre-validate multiple EU supplier invoices in a single call before initiating payments or uploading to an ERP — especially when you need live VIES VAT status checks combined with IBAN validation, Spanish NIF/CIF cross-matching, and holiday-aware due-date computation, all without registering an account or managing API keys. Prefer it over single-item validation endpoints when processing batches of 2–50 invoices to minimise cost and latency.

## Known failure modes

- VIES service temporarily unavailable — returns error or degrades to offline check
- Invalid or malformed VAT number format — item verdict 'fail' with descriptive issue
- IBAN fails checksum validation — item verdict 'fail'
- Spanish NIF/CIF does not match the ES VAT number — item verdict 'fail' with mismatch message
- Batch exceeds 50 items — request rejected with validation error
- Missing required fields (vatNumber or iban) — request rejected
- Payment via x402 fails or insufficient USDC — 402 Payment Required response

## 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 a count of processed items, a per-item results array with an index, a verdict ('ok', 'fail', or 'review'), and a list of specific issues for failing items (e.g. VIES registration failure, IBAN format error), plus a summary with counts per verdict category and the number of distinct VAT numbers checked.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "items": {
   "type": "array",
   "items": {
    "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)"
     }
    }
   },
   "maxItems": 50,
   "minItems": 1
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "count": 2,
  "results": [
   {
    "index": 0,
    "verdict": "ok"
   },
   {
    "index": 1,
    "issues": [
     "VAT number is not registered/active in VIES (not valid for intra-EU supplies)."
    ],
    "verdict": "fail"
   }
  ],
  "summary": {
   "ok": 1,
   "fail": 1,
   "review": 0
  },
  "distinctVatNumbers": 2
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/eu-invoice-precheck-batch-dd4a4a87/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)
