// *******************************************
// Create the database table layout
// *******************************************
  
CREATE TABLE ozekicallsin (
id INTEGER PRIMARY KEY,
sender VARCHAR(255),
receiver VARCHAR(255),
msg LONGTEXT,
senttime VARCHAR(100),
receivedtime VARCHAR(100),
operator VARCHAR(30),
reference VARCHAR(30),
);

CREATE TABLE ozekicallsout (
id INTEGER PRIMARY KEY,
sender VARCHAR(255),
receiver VARCHAR(255),
msg LONGTEXT,
callid VARCHAR(255),
startime VARCHAR(40),
endtime VARCHAR(40),
status VARCHAR(40),
talkduration VARCHAR(40),
ringduration VARCHAR(40),
operator VARCHAR(100),
errormsg VARCHAR(250)
);
    
CREATE TABLE ozekicallscripts (
id INTEGER PRIMARY KEY,
msg LONGTEXT,
phonenumber VARCHAR(40)
);

// *******************************************
// How to make a call: example 1
// The script is in the ozekicallsout table
// *******************************************

INSERT INTO ozekicallsout (status,receiver,msg)
VALUES ('send','101','
<?xml version="1.0"?>
<Response>
	<Request>
        <OnAnswered>
            <Speak Party="caller">You will get dtmf keys 123.</Speak>
            <SendDTMF Party="caller" Keys="123"></SendDTMF>
            <Hangup/>
        </OnAnswered>
    </Request>
</Response>
')

// *******************************************
// How to make a call: example 2
// The script is in a file on drive C
// *******************************************

INSERT INTO ozekicallsout (status,receiver,msg) VALUES ('send','101','C:\ozml\script.ozml')

// *******************************************
// How to make a call: example 3
// The script is in the ozekicallscripts table
// *******************************************


INSERT INTO ozekicallscripts (id,msg)
VALUES ('1','
<?xml version="1.0"?>
<Response>
	<Request>
        <OnAnswered>
            <Speak Party="caller">You are using call script 1. Thank you for calling. </Speak>
            <Hangup/>
        </OnAnswered>
    </Request>
</Response>
')

INSERT INTO ozekicallsout (status,receiver,msg) VALUES ('send','101','1')

More information