cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
73
Views
0
Helpful
0
Comments
cdnadmin
Level 11
Level 11
This document was generated from CDN thread

Created by: Dave Stewart on 25-05-2010 06:10:22 AM
I am trying to understand how to best handle the situation when a Dial command is placed, but the number I'm dialing is already in use (busy). 

In my testing with TCS 4.0 API software, I am performing the following steps, which work if the dialed number is available to accept a call:

RequestConferenceID  returns a ConferenceID which is used for all future steps

GetConference returns basic metadata on the Conference, duration 0

GetCallInfo returns NOT_IN_CALL  (correct at this stage)

Dial returns no Error and Error Code = 0 (success)

but when the number is busy

GetConference returns:
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope">
   <env:Body>
      <env:Fault>
         <env:Code>
            <env pac-man alue>env:Receiver</env pac-man alue>
         </env:Code>
         <env:Reason>
            <env:Text>Unknown ConferenceID</env:Text>
         </env:Reason>
      </env:Fault>
   </env:Body>
</env:Envelope>

And GetCallInfo returns essentially the same thing:
         <env:Reason>
            <env:Text>Invalid Parameter: ConferenceID</env:Text>
         </env:Reason>

What is the proper way to check for call progress and completion?    Is there some other way to understand what happened to a ConferenceID when a call doesn't complete as expected?

Thanks,
Dave

Subject: RE: handling an uncompleted call
Replied by: Jesse Baker on 25-05-2010 06:39:38 AM
Hi David,

The issue here is dial time vs API response time. We chose to respond to the dial request immediately with success indicating that the TCS has the capability to make the call.

You have a couple of options:
1. Poll the http://<server>/tcs/Status.xml document (or use the API function GetStatus) to check for live calls, if your call doesn't transition into a state of IN_CALL then it failed. However, using this technique provides no easy way to determine why the call failed.

2. Use the AddManagementSystem mechanism to add a post-back URL to the TCS. This will instruct the TCS to send XML HTTP posts to the indicated URLs. The external management system functionality is available in TCS version 4.0 and above.

Hope that helps!

Jesse Baker

Subject: RE: handling an uncompleted call
Replied by: Dave Stewart on 25-05-2010 06:47:53 AM
Jesse,

Thank you, that is a big help. 

I looked at the getStatus for call information, and I can match with my existing conference ID, but, as you say, you can only determine that it failed, not why it failed, or what to do about it.

Is there any documentation on the management API?  Registration seems simple enough, but I'd like to know what to expect in the HTTP posts.

Thanks, again,
Dave

Subject: RE: handling an uncompleted call
Replied by: Jesse Baker on 25-05-2010 07:03:10 AM
The XML schema and examples are not currently included in the TCS documentation. XML post messages conform to the following schema:

 1<xs:schema id="Status" targetNamespace="http://www.tandberg.no/XML/CUIL/1.0"
 2    xmlns="http://www.tandberg.no/XML/CUIL/1.0"
 3    xmlns:xs="http://www.w3.org/2001/XMLSchema"
 4    elementFormDefault="qualified">
 5
 6    <xs:group name="callData">
 7        <xs:sequence>
 8            <xs:element name="ConferenceID" type="xs:string"/>
 9            <xs:element name="RecordingAliasID" type="xs:string"/>
10            <xs:element name="TranscodingModel">
11                <xs:simpleType>
12                    <xs:restriction base="xs:string">
13                        <xs:enumeration value="live"/>
14                        <xs:enumeration value="normal"/>
15                    </xs:restriction>
16                </xs:simpleType>
17            </xs:element>
18        </xs:sequence>
19    </xs:group>
20
21    <xs:group name="callEndData">
22        <xs:sequence>
23            <xs:element name="DisconnectCauseValue" type="xs:string"/>
24            <xs:element name="DisconnectCause" type="xs:string"/>
25            <xs:group ref="callData"/>
26        </xs:sequence>
27    </xs:group>
28
29    <xs:element name="Status">
30        <xs:complexType>
31            <xs:sequence>
32
33                <xs:element name="Identification">
34                    <xs:complexType>
35                        <xs:sequence>
36                            <xs:element name="SystemName" type="xs:string"/>
37                            <xs:element name="MACAddress" type="xs:string"/>
38                            <xs:element name="IPAddress" type="xs:string"/>
39                            <xs:element name="ProductType" type="xs:string"/>
40                            <xs:element name="ProductID" type="xs:string"/>
41                            <xs:element name="SWVersion" type="xs:string"/>
42                            <xs:element name="SerialNumber" type="xs:string"/>
43                        </xs:sequence>
44                    </xs:complexType>
45                </xs:element>
46
47                <xs:element name="H323Gatekeeper" minOccurs="0">
48                    <xs:complexType>
49                        <xs:sequence>
50                            <xs:element name="Address" type="xs:string"/>
51                            <xs:element name="Port" type="xs:integer"/>
52                        </xs:sequence>
53                        <xs:attribute name="status">
54                            <xs:simpleType>
55                                <xs:restriction base="xs:string">
56                                    <xs:enumeration value="Registered"/>
57                                    <xs:enumeration value="Rejected"/>
58                                    <xs:enumeration value="Inactive"/>
59                                </xs:restriction>
60                            </xs:simpleType>
61                        </xs:attribute>
62                    </xs:complexType>
63                </xs:element>
64
65                <xs:element name="Event" minOccurs="0">
66                    <xs:complexType>
67                        <xs:choice>
68                            <xs:group ref="callData"/>
69                            <xs:group ref="callEndData"/>
70                        </xs:choice>
71                        <xs:attribute name="type">
72                            <xs:simpleType>
73                                <xs:restriction base="xs:string">
74                                    <xs:enumeration value="CallConnecting"/>
75                                    <xs:enumeration value="CallConnected"/>
76                                    <xs:enumeration value="CallRejected"/>
77                                    <xs:enumeration value="CallDisconnected"/>
78                                </xs:restriction>
79                            </xs:simpleType>
80                        </xs:attribute>
81                        <xs:attribute name="tagId" type="xs:integer" />
82                    </xs:complexType>
83                </xs:element>
84
85            </xs:sequence>
86        </xs:complexType>
87    </xs:element>
88</xs:schema>


An example of such a message would be:

 1<?xml version="1.0"?>
 2<Status xmlns="http://www.tandberg.no/XML/CUIL/1.0">
 3    <Identification>
 4        <SystemName>My TCS</SystemName>
 5        <MACAddress>00:00:00:00:00:00</MACAddress>
 6        <IPAddress>0.0.0.0</IPAddress>
 7        <ProductType>TANDBERG Network</ProductType>
 8        <ProductID>TANDBERG Content Server</ProductID>
 9        <SWVersion>S4.0</SWVersion>
10        <SerialNumber>4900000</SerialNumber>
11    </Identification>
12    <Event type="CallRejected" tagId="1">
13        <DisconnectCauseValue>17</DisconnectCauseValue>
14        <DisconnectCause>Far end busy</DisconnectCause>
15        <ConferenceID>6C573098-2E9C-44C2-AA33-A972AEAA0876</ConferenceID>
16        <RecordingAliasID>6C573098-2E9C-44C2-AA33-A972AEAA0877</RecordingAliasID>
17        <TranscodingModel>live</TranscodingModel>
18    </Event>
19</Status>


Cheers,

Jesse Baker
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Quick Links