{
  "openapi": "3.0.1",
  "info": {
    "title": "EU VAT Number Validator & KYB Checker",
    "description": "Bulk-validate EU VAT numbers against the official VIES service. Offline checksum pre-filtering, member-state outage detection, consultation numbers for audit evidence, and company-name matching.",
    "version": "1.0",
    "x-build-id": "HQ3hdJ2ZCFyQZgBM4"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/act2labs~vies-vat-verification/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-act2labs-vies-vat-verification",
        "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/act2labs~vies-vat-verification/runs": {
      "post": {
        "operationId": "runs-sync-act2labs-vies-vat-verification",
        "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/act2labs~vies-vat-verification/run-sync": {
      "post": {
        "operationId": "run-sync-act2labs-vies-vat-verification",
        "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",
        "properties": {
          "vatNumbers": {
            "title": "VAT numbers",
            "type": "array",
            "description": "One VAT number per line, with or without the country prefix and with any spacing you like. Examples: DE136695976, FR 40 303 265 045, ie6388047v. GR is accepted as an alias for EL.",
            "items": {
              "type": "string"
            }
          },
          "records": {
            "title": "Records (for KYB / name matching)",
            "type": "array",
            "description": "Use this instead of the plain list when you also want to check that the registered company name matches what you have on file. Each object accepts: vatNumber (required), expectedName, reference."
          },
          "requesterVatNumber": {
            "title": "Your own VAT number (for consultation numbers)",
            "type": "string",
            "description": "Supply your own VAT registration to receive a VIES consultation number (requestIdentifier) with every result. That identifier is the only artifact that later proves you verified a counterparty on a given date, under Article 31 of Regulation 904/2010, and it cannot be obtained retroactively. It must be an EU member-state VAT number or a Northern Ireland (XI) one - Great Britain is not part of VIES. A 10-digit UK number is a Unique Taxpayer Reference, not a VAT number."
          },
          "defaultCountryCode": {
            "title": "Default country code",
            "enum": [
              "",
              "AT",
              "BE",
              "BG",
              "CY",
              "CZ",
              "DE",
              "DK",
              "EE",
              "EL",
              "ES",
              "FI",
              "FR",
              "HR",
              "HU",
              "IE",
              "IT",
              "LT",
              "LU",
              "LV",
              "MT",
              "NL",
              "PL",
              "PT",
              "RO",
              "SE",
              "SI",
              "SK",
              "XI",
              "GB"
            ],
            "type": "string",
            "description": "Used for rows that have no country prefix. Leave empty to require a prefix on every number.",
            "default": ""
          },
          "skipInvalidFormat": {
            "title": "Reject malformed numbers offline",
            "type": "boolean",
            "description": "On by default. Numbers that fail their country's checksum are rejected without spending a VIES call, which is faster and cheaper. Turn this off to force every row through VIES regardless.",
            "default": true
          },
          "checkMemberStateAvailability": {
            "title": "Check member-state availability first",
            "type": "boolean",
            "description": "On by default. Queries the VIES status endpoint before starting so that a national database outage is reported as 'unverifiable' rather than being mistaken for an invalid VAT number.",
            "default": true
          },
          "maxConcurrency": {
            "title": "Maximum concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many member states to query in parallel. Calls to a single member state are always serialised, because VIES throttles by concurrency and will block your IP if pushed. Raising this above 8 is rarely useful.",
            "default": 4
          },
          "maxRetries": {
            "title": "Retries per number",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Retry attempts, with exponential backoff, when VIES returns a transient error such as a timeout or a concurrency limit.",
            "default": 4
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}