{
  "openapi": "3.0.1",
  "info": {
    "title": "Phone Number Validator & Formatter – Bulk, Carrier, Line Type",
    "description": "Validate and format phone numbers in bulk for 240+ countries: valid/possible, E.164, international and national formats, mobile/fixed/VoIP/toll-free type, original carrier, location and time zones. Offline Google libphonenumber - fast and cheap, 100k numbers per run.",
    "version": "0.1",
    "x-build-id": "caztxMPbFCQZh4dYH"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gazidev~phone-validator/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gazidev-phone-validator",
        "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/gazidev~phone-validator/runs": {
      "post": {
        "operationId": "runs-sync-gazidev-phone-validator",
        "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/gazidev~phone-validator/run-sync": {
      "post": {
        "operationId": "run-sync-gazidev-phone-validator",
        "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": {
          "phoneNumbers": {
            "title": "Phone numbers",
            "type": "array",
            "description": "Phone numbers in any format: `+44 20 7946 0958`, `(201) 555-0123`, `0049 30 2270`, `1-800-FLOWERS`, `+1 650 253 0000 ext. 12`. Numbers without `+`/`00` use the default country below.",
            "default": [
              "+1 650-253-0000",
              "+44 20 7946 0958",
              "0049 30 2270"
            ],
            "items": {
              "type": "string"
            }
          },
          "defaultCountry": {
            "title": "Default country (ISO code)",
            "type": "string",
            "description": "Two-letter ISO country code (US, GB, DE, IN, BR, TR...) used for numbers written without `+` or `00`, e.g. `(201) 555-0123`. Leave empty if all numbers are international. A country column in your CSV/dataset overrides it per row.",
            "default": ""
          },
          "bulkText": {
            "title": "Bulk list (paste numbers or CSV)",
            "type": "string",
            "description": "Paste one number per line, or a whole CSV/TSV export with a header row (the phone column is detected automatically, or set it below)."
          },
          "sourceFileUrl": {
            "title": "CSV / TXT file URL",
            "type": "string",
            "description": "Public URL of a .csv or .txt file, e.g. a Google Sheets 'Publish to web' CSV link or an Apify key-value store record URL."
          },
          "datasetId": {
            "title": "Apify dataset ID",
            "type": "string",
            "description": "Validate phone numbers from another Actor's dataset (e.g. Google Maps or contact scrapers). The phone field is auto-detected; fields holding a list of phones are expanded."
          },
          "phoneColumn": {
            "title": "Phone column / field name",
            "type": "string",
            "description": "Column (CSV) or field (dataset) that holds the phone number. Empty = auto-detect (phone, tel, mobile, number...)."
          },
          "countryColumn": {
            "title": "Country column / field name (optional)",
            "type": "string",
            "description": "Column with a per-row ISO country code (or calling code like 49). Empty = auto-detect a column named country / countryCode / iso."
          },
          "keepFields": {
            "title": "Copy these columns to the output",
            "type": "array",
            "description": "CSV columns or dataset fields to copy into each result under `record` (e.g. `id`, `name`, `email`) so you can join results back to your CRM.",
            "items": {
              "type": "string"
            }
          },
          "dedupe": {
            "title": "Remove duplicates",
            "type": "boolean",
            "description": "Keep only the first occurrence of each number (compared in E.164, so `+1 650-253-0000` and `(650) 253 0000` are the same). Duplicates are not charged.",
            "default": true
          },
          "outputFilter": {
            "title": "Output",
            "enum": [
              "all",
              "valid",
              "invalid"
            ],
            "type": "string",
            "description": "Save all numbers, only valid ones or only invalid ones. Hidden numbers are not charged.",
            "default": "all"
          },
          "includeCarrier": {
            "title": "Original carrier name",
            "type": "boolean",
            "description": "Carrier the number range was allocated to (mobile numbers). Ported numbers may show the original carrier, not the current one.",
            "default": true
          },
          "includeLocation": {
            "title": "Location (city / region)",
            "type": "boolean",
            "description": "Geographic description of the number range, e.g. `Mountain View, CA` or `London`.",
            "default": true
          },
          "includeTimeZones": {
            "title": "Time zones",
            "type": "boolean",
            "description": "IANA time zones for the number, handy for call scheduling.",
            "default": true
          },
          "language": {
            "title": "Language for carrier and location names",
            "type": "string",
            "description": "Language code for location/carrier names where available (en, de, fr, es, zh, ja, ...). Falls back to English.",
            "default": "en"
          },
          "assumeInternational": {
            "title": "Treat long numbers without + as international",
            "type": "boolean",
            "description": "When no default/row country is known, try `4915123456789` as `+49 1512 3456789`. The result shows `parsedAs: assumed_international`.",
            "default": true
          },
          "maxNumbers": {
            "title": "Max numbers",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many input numbers (0 = no limit). Useful to test a big file cheaply.",
            "default": 0
          }
        }
      },
      "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}