{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/agentline-cloud/json-schema/agentline-cloud-number-provision-schema.json",
  "title": "NumberProvision",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/agentline-cloud-numbers-api-openapi.yml#/components/schemas/NumberProvision",
  "properties": {
    "agent_id": {
      "type": "string",
      "title": "Agent Id",
      "description": "ID of the AI agent to assign this phone number to (e.g. 'agt_abc123')"
    },
    "country": {
      "type": "string",
      "title": "Country",
      "description": "Country code for the phone number ('US' or 'CA')",
      "default": "US"
    },
    "number_type": {
      "type": "string",
      "title": "Number Type",
      "description": "Type of phone number: 'local' or 'tollfree'",
      "default": "local"
    },
    "area_code": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Area Code",
      "description": "Preferred 3-digit US area code (e.g. '212' for NYC, '415' for SF, '310' for LA)"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Pattern",
      "description": "Legacy digit pattern match (prefer area_code instead)"
    }
  },
  "type": "object",
  "required": [
    "agent_id"
  ]
}