{
  "openapi": "3.0.1",
  "info": {
    "title": "EU VAT Number Validation: Bulk VIES Check & Supplier Monitor",
    "description": "Validate a whole supplier or customer list against VIES, get the consultation number that proves you checked, and be told the moment a VAT number goes invalid or its registered name changes. Knows the difference between an invalid number and a member state that is simply down.",
    "version": "0.1",
    "x-build-id": "3xeYhoKdYrfCs1cbS"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/fayoussef~eu-vat-compliance-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-fayoussef-eu-vat-compliance-monitor",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/fayoussef~eu-vat-compliance-monitor/runs": {
      "post": {
        "operationId": "runs-sync-fayoussef-eu-vat-compliance-monitor",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/fayoussef~eu-vat-compliance-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-fayoussef-eu-vat-compliance-monitor",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "required": [
          "vatNumbers"
        ],
        "properties": {
          "vatNumbers": {
            "title": "VAT numbers to check",
            "type": "array",
            "description": "One per line, with the country code in front: DE811569869. Add the name you have on file after a pipe to be told when the registered name no longer matches: DE811569869 | Acme Widgets GmbH. Spaces, dots and dashes are ignored, so you can paste straight from an ERP export. GR is accepted as a synonym for EL. Names are compared in the script they are written in, so a supplier registered in Greek or Bulgarian is best left without a name on file.",
            "default": [
              "IE6388047V | Google Ireland Limited",
              "DE811569869 | Zalando SE",
              "IT00488410010 | TIM S.p.A.",
              "PL5260250995 | Orange Polska",
              "SE556036079301 | Saab AB",
              "ES A28017895 | Telefonica",
              "EL094019245"
            ],
            "items": {
              "type": "string"
            }
          },
          "requesterVatNumber": {
            "title": "Your own VAT number (for proof of consultation)",
            "type": "string",
            "description": "Optional but strongly recommended. Supply your own EU VAT number and VIES returns a consultation number for every check, which is the reference a tax authority accepts as evidence that you validated the counterparty on that date. Leave it empty and you still get the verdict, just no reference number to cite."
          },
          "nameMatchThreshold": {
            "title": "Name match threshold",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "How much of your own name for a company has to appear in the registered name before it counts as the same company, as a percentage. Legal forms such as GmbH, SARL and Ltd are ignored on both sides, so 60 is a sensible default. Some member states, Germany among them, confirm a number without disclosing any name: those are reported as \"not disclosed\" rather than as a mismatch.",
            "default": 60
          },
          "alertsOnly": {
            "title": "Only return numbers that need attention",
            "type": "boolean",
            "description": "Leave this off to get every number back with its verdict, which is what an audit file needs. Turn it on to get only the invalid, mismatched and unchecked ones, which is what a monthly review needs.",
            "default": false
          },
          "onlyChangesSinceLastRun": {
            "title": "Only return what changed since the last run",
            "type": "boolean",
            "description": "The point of running this on a schedule. A quiet month then produces an empty dataset instead of the same list again. The first run always returns everything, because nothing has changed yet.",
            "default": false
          },
          "trackChanges": {
            "title": "Remember this list between runs",
            "type": "boolean",
            "description": "Keeps a small fingerprint of each number's verdict and registered name so the next run can tell you which supplier went bad. Turn it off for a one-off check that should leave nothing behind.",
            "default": true
          },
          "watchlistName": {
            "title": "Watchlist name",
            "type": "string",
            "description": "The name of the history this run compares against. Use a different name per list, for example \"suppliers\" and \"customers\", and each keeps its own baseline. Changing this name starts a fresh history, so the next run reports everything as new.",
            "default": "default"
          },
          "maxVatNumbers": {
            "title": "Maximum VAT numbers per run",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "A safety cap on how much of the list one run will check. Lines beyond it are skipped and the run says so.",
            "default": 500
          },
          "slackWebhookUrl": {
            "title": "Slack webhook URL",
            "type": "string",
            "description": "Optional. Post the numbers that need attention to a Slack channel. Nothing is sent when nothing needs attention, so a quiet channel means a clean supplier list."
          },
          "discordWebhookUrl": {
            "title": "Discord webhook URL",
            "type": "string",
            "description": "Optional. Post the same digest to a Discord channel."
          },
          "telegramChatId": {
            "title": "Telegram chat ID",
            "type": "string",
            "description": "Optional. The chat to send the digest to. Fill this in together with the bot token below."
          },
          "telegramBotToken": {
            "title": "Telegram bot token",
            "type": "string",
            "description": "Optional. Your own bot's token, used only to deliver the digest to the chat above."
          },
          "webhookUrl": {
            "title": "Webhook URL",
            "type": "string",
            "description": "Optional. Receive the alerts as JSON, for Zapier, Make, n8n or your own endpoint."
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}