{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://jambonz.org/schema/callbacks/session-redirect",
  "title": "Session:redirect Payload",
  "description": "Payload delivered when a redirect verb transfers the call to a new application or WebSocket endpoint. Contains only the current call state information — unlike session:new, it does not include defaults, env_vars, sip, or service_provider_sid.",
  "allOf": [
    { "$ref": "base" }
  ],
  "type": "object",
  "properties": {
    "caller_name": {
      "type": "string",
      "description": "Caller display name from the SIP From header."
    },
    "caller_id": {
      "type": "string",
      "description": "Caller ID value (phone number or SIP user)."
    },
    "parent_call_sid": {
      "type": "string",
      "description": "Call SID of the parent call, if applicable."
    },
    "fs_sip_address": {
      "type": "string",
      "description": "Internal SIP address of the FreeSWITCH media server handling this call."
    },
    "fs_public_ip": {
      "type": "string",
      "description": "Public IP address of the FreeSWITCH media server, if available."
    },
    "customerData": {
      "type": "object",
      "description": "Custom data attached to the call via the REST API. Preserved as-is (not snake-cased).",
      "additionalProperties": true
    }
  },
  "additionalProperties": true
}
