{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/TestCallRoutingPostResponse",
  "title": "TestCallRoutingPostResponse",
  "type": "object",
  "required": [
    "destinationType",
    "routingAddress",
    "isRejected"
  ],
  "properties": {
    "callSourceInfo": {
      "$ref": "#/components/schemas/CallSourceInfo",
      "description": "Only returned when `originatorNumber` is specified in the request."
    },
    "destinationType": {
      "$ref": "#/components/schemas/CallDestinationType",
      "description": "Destination type for the call."
    },
    "routingAddress": {
      "type": "string",
      "example": "007",
      "description": "FAC code if `destinationType` is FAC. The routing address will be returned for all other destination types."
    },
    "outsideAccessCode": {
      "type": "string",
      "example": "1234",
      "description": "Outside access code."
    },
    "isRejected": {
      "type": "boolean",
      "description": "`true` if the call would be rejected."
    },
    "hostedAgent": {
      "$ref": "#/components/schemas/HostedAgent",
      "description": "Returned when `destinationType` is `HOSTED_AGENT`."
    },
    "hostedFeature": {
      "$ref": "#/components/schemas/HostedFeature",
      "description": "Returned when `destinationType` is `HOSTED_FEATURE`."
    },
    "pbxUser": {
      "$ref": "#/components/schemas/PbxUser",
      "description": "Returned when `destinationType` is `PBX_USER`."
    },
    "pstnNumber": {
      "$ref": "#/components/schemas/PstnNumber",
      "description": "Returned when `destinationType` is `PSTN_NUMBER`."
    },
    "virtualExtension": {
      "$ref": "#/components/schemas/VirtualExtension",
      "description": "Returned when `destinationType` is `VIRTUAL_EXTENSION`."
    },
    "virtualExtensionRange": {
      "$ref": "#/components/schemas/VirtualExtensionRange",
      "description": "Returned when `destinationType` is `VIRTUAL_EXTENSION_RANGE`."
    },
    "routeList": {
      "$ref": "#/components/schemas/RouteList",
      "description": "Returned when `destinationType` is `ROUTE_LIST`."
    },
    "featureAccessCode": {
      "$ref": "#/components/schemas/FeatureAccessCode",
      "description": "Returned when `destinationType` is `FAC`."
    },
    "emergency": {
      "$ref": "#/components/schemas/Emergency",
      "description": "Returned when `destinationType` is `EMERGENCY`."
    },
    "repair": {
      "$ref": "#/components/schemas/Repair",
      "description": "Returned when `destinationType` is `REPAIR`."
    },
    "unknownExtension": {
      "$ref": "#/components/schemas/UnknownExtension",
      "description": "Returned when `destinationType` is `UNKNOWN_EXTENSION`."
    },
    "unknownNumber": {
      "$ref": "#/components/schemas/UnknownNumber",
      "description": "Returned when `destinationType` is `UNKNOWN_NUMBER`."
    },
    "appliedServices": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/AppliedServices"
      },
      "description": "Returned if any origin is configured with intercept details, outgoing permissions by type, or translation pattern."
    }
  }
}