You are here: CSP Developer’s Guide: Internet Protocols > 5 Call Agent > NPDI Data Model
Overview
The Call Agent feature uses an NPDI data model that is structured to represent a multimedia call scenario. This call scenario has a single calling session and multiple underlying media sessions for carrying audio, video, and application data media streams. Each media stream is described by an "m=" line in the Session Description Protocol (SDP).
SIP is the signaling protocol used in the example but other IP signaling protocols could be used in the future.
The NPDI data model is hierarchical. It can have multiple levels of media streams in a call, and multiple codecs within a media stream. You can have a maximum of four media streams and eight codecs per media stream.
The following figure shows the NPDI data model with its flat call session data and nested media description data.
This figure shows how the data must be nested in TLVs. For example, the Per Media Stream Data and Per Codec Data must be nested as indicated in the figure.
Figure 5-2 NPDI Data Model
During the call setup, the originating SIP end point typically puts out a set of media sessions, each with a set of codec capabilities. In addition, each codec within a media stream can have its own attributes such as payload type and size. When setting up a call, the SIP software on the CSP consolidates media session parameters into two Session Description Data TLVs.
• Media Local End Point TLV (0x29FF)
• Media Remote End Point TLV (0x2A00)
Other TLVs containing additional information are nested below these two TLVs. Refer to the following TLVs in the Tag Length Value chapter of the API Reference:
• 0x2954 SIP Request URI User Name
• 0x2A00 Media Remote End Point Information
• 0x2A01 Media Per Stream Information
• 0x2A02 Media Per Codec Information
• 0x2A03 Media Type
• 0x2A07 Media Port
• 0x2A08 Media Payload Type
• 0x2A09 Media Payload Description
• 0x2A0A Media Payload Size
• 0x2A0B Media Clock Rate
• 0x2A0E Media Connection Address
• 0x2A13 Media Flow Direction
The SIP end points negotiate media parameters to set up the call based on their respective capabilities. For example, one SIP phone might accommodate audio, video and fax, while another might accommodate audio, fax, and SMS (Instant Messaging). When a call is made between the two, they can exchange audio and fax, but not video or SMS streams.
In this example, two SIP endpoints negotiate to set up streams for audio and fax, but ignore video and SMS. Because each stream’s codecs are nested within a high-level TLV, the TLVs for the streams not being used can be ignored by the host application.
This data model does not place any restrictions on the placement and positioning of individual TLVs between call signaling and media description areas. The TLVs can be placed between two areas based on the call scenario and data available on the signaling front.
NPDI Local and Remote Media Parameters
As described above, the SIP software on the CSP consolidates media session parameters into a Session Description Data TLV when setting up a call.
For bearer-free calls, the end point’s Session Description Data is considered local or remote, depending on the span/channel that the call is on. (Note: This concept does not apply to bearer calls.)
When the call comes into the CSP, a Request for Service message with span/channel information is sent to the host application and this side of the call is considered local. The other end point is considered remote.
See the Call Flow for more information on the local and remote sides.
The call flow below details each step of the call setup for a bearer-free call.
Important! When an end point causes the CSP to send an API message to the host application that end point as well as the associated span/channel is considered the local side. (In the call flow above, these messages are the Request for Service with Data and PPL Event Indication messages.)
An incoming call manifests a Request for Service with Data message that from the CSP to the host that contains the NPDI Media Local End Point TLV (0x29FF) in the Session Description Data of the local side (channel A) of the call.
In order to switch the call to the egress side, the host delivers a Route Control message to the CSP. Apart from signaling the egress call, the Route Control message conveys channel A’s media parameters to channel B. In order to indicate to channel B that the media parameters contained in the Route Control message belong to channel A, the host application copies over the NPDI Media Local End Point TLV (0x29FF) from the Request for Service with Data message to the NPDI Media Remote End Point TLV (0x2A00).
Conversely, the host application assigns the Media Remote End Point TLV (0x2A00) to the Session Description Data of the remote side (channel B) of the call. This happens in the Route Control message that the host sends to the CSP.
At this point, channel B knows about the channel A media parameters but channel A does not know about the channel B media parameters. Upon receipt of the media parameters over signaling, the channel B side sends its media parameters to the host in the PPL Event Indication message. The host application copies the contents of the PPL Event Indication (TLV 0x29FF) into the Connect with Data message (TLV 0x2A00) and sends it to the CSP. Evidently both channel A and channel B are now aware of each other’s media parameters, as required for media communication to begin.
The following is a sample message trace for this process.
X->H
[00 e7 00 2d 00 17 ff 00 01 0d 03 00 07 13 00 33 01 03 00 33
00 d3 00 0b 27 4e 00 02 00 05 27 7e 00 03 08 00 00 29
19 00 05 31 32 33 34 00 29 1b 00 0d 31 30 2e 31 30 2e
31 30 30 2e 31 30 00 29 23 00 05 34 34 34 34 00 29 25
00 0d 31 30 2e 31 30 2e 31 30 30 2e 31 30 00 29 2d 00
05 34 34 34 34 00 29 2f 00 0d 31 30 2e 31 30 2e 31 30
30 2e 34 30 00 27 18 00 07 02 00 00 00 04 44 44 27 17
00 05 02 00 04 12 34 29 ff 00 5e 2a 0e 00 04 0a 0a 64
28 2a 01 00 52 2a 03 00 01 00 2a 07 00 04 00 00 22 3e
2a 02 00 13 2a 08 00 02 00 02 2a 09 00 01 02 2a 0b 00
04 00 00 1f 40 2a 02 00 13 2a 08 00 02 01 60 2a 09 00
01 32 2a 0b 00 04 00 00 1f 40 2a 02 00 13 2a 08 00 02
00 01 2a 09 00 01 01 2a 0b 00 04 00 00 1f 40]
H->X
[00 0c 00 2d 00 17 ff 00 01 0d 03 00 07 13]
H->X
[00 ac 00 e8 00 01 ff 00 01 29 02 ff fe 02 03 00 1e 00
19 00 04 00 13 00 02 00 08 00 08 00 02 00 71 00 0f 00
01 0b 00 71 00 02 00 00 03 00 33 00 7d 00 04 27 7e 00
03 08 01 00 29 23 00 05 34 34 34 34 00 29 19 00 05 31
32 33 34 00 2a 00 00 5e 2a 0e 00 04 0a 0a 64 28 2a 01
00 52 2a 03 00 01 00 2a 07 00 04 00 00 22 3e 2a 02 00
13 2a 08 00 02 00 02 2a 09 00 01 02 2a 0b 00 04 00 00
1f 40 2a 02 00 13 2a 08 00 02 01 60 2a 09 00 01 32 2a
0b 00 04 00 00 1f 40 2a 02 00 13 2a 08 00 02 00 01 2a
09 00 01 01 2a 0b 00 04 00 00 1f 40]
X->H
[00 14 00 e8 00 01 ff 00 10 01 02 1e 09 00 01 00 39 00 03 00 07 14]
H->X
[00 11 00 bf 00 01 ff 00 02 0d 03 00 07 13 0d 03 00 07
13]
X->H
[00 07 00 bf 00 01 ff 00 10]
X->H
[00 63 00 43 00 03 ff 00 01 0d 03 00 07 14 00 a7 00 20 01 03
00 33 00 4d 00 01 29 ff 00 47 2a 0e 00 04 0a 0a 64 05
2a 01 00 3b 2a 03 00 01 00 2a 07 00 04 00 00 8e 30 2a
02 00 13 2a 08 00 02 00 02 2a 09 00 01 02 2a 0b 00 04
00 00 1f 40 2a 02 00 13 2a 08 00 02 00 01 2a 09 00 01
01 2a 0b 00 04 00 00 1f 40]
H->X
[00 05 00 43 00 03 ff]
H->X
[00 72 00 05 00 01 ff 00 02 0d 03 00 07 13 0d 03 00 07
14 01 02 03 00 1e 00 08 00 01 01 16 00 02 00 01 03 00
33 00 4d 00 01 2a 00 00 47 2a 0e 00 04 0a 0a 64 05 2a
01 00 3b 2a 03 00 01 00 2a 07 00 04 00 00 8e 30 2a 02
00 13 2a 08 00 02 00 02 2a 09 00 01 02 2a 0b 00 04 00
00 1f 40 2a 02 00 13 2a 08 00 02 00 01 2a 09 00 01 01
2a 0b 00 04 00 00 1f 40]
X->H
[00 07 00 05 00 01 ff 00 10]
1 -RECEIVED From 10.10.100.40:1028 at 2588
INVITE sip:1234@10.10.100.10 SIP/2.0
From: sip:4444@10.10.100.10;tag=1c29051
To: sip:1234@10.10.100.10
Call-Id: call-973574993-5@10.10.100.40
Cseq: 1 INVITE
Contact: sip:4444@10.10.100.40
Content-Type: application/sdp
Content-Length: 197
Accept-Language: en
Allow: INVITE, ACK, CANCEL, BYE, REFER, OPTIONS, NOTIFY, REGISTER, SUBSCRIBE
Supported: sip-cc, sip-cc-01, timer
User-Agent: Pingtel/1.2.6 (VxWorks)
Via: SIP/2.0/UDP 10.10.100.40
v=0
o=Pingtel 5 5 IN IP4 10.10.100.40
s=phone-call
c=IN IP4 10.10.100.40
t=0 0
m=audio 8766 RTP/AVP 0 96 8
a=rtpmap:0 pcmu/8000/1
a=rtpmap:96 telephone-event/8000/1
a=rtpmap:8 pcma/8000/1
2 -SENT To 10.10.100.40:5060 at 2588
SIP/2.0 100 Trying
To: sip:1234@10.10.100.10;tag=4206a1c
From: sip:4444@10.10.100.10;tag=1c29051
Call-ID: call-973574993-5@10.10.100.40
CSeq: 1 INVITE
Contact: 1234<sip:1234@10.10.100.10:5060>
Via: SIP/2.0/UDP 10.10.100.40
User-Agent: Excel/82.0.66
Content-Length: 0
3 -SENT To 10.10.100.5:8982 at 2589
INVITE sip:10.10.100.5:8982 SIP/2.0
Via: SIP/2.0/UDP 10.10.100.10
To: 1234<sip:1234@10.10.100.5:8982>
From: 4444<sip:4444@10.10.100.10:5060>;tag=41165572a1d
Call-ID: Excel-CSP255.1014.2589.0@10.10.100.10
Contact: 4444<sip:4444@10.10.100.10:5060>
User-Agent: Excel/82.0.66
Supported: timer
Session-Expires: 1800
Min-SE: 300
CSeq: 1 INVITE
Content-Type: application/sdp
Content-Length: 202
v=0
o=sip 946687389 946687389 IN IP4 10.10.100.10
s=SIP_Call
c=IN IP4 10.10.100.40
t=0 0
m=audio 8766 RTP/AVP 0 96 8
a=rtpmap:0 PCMU/8000
a=rtpmap:96 telephone-event/8000
a=rtpmap:8 PCMA/8000
4 -RECEIVED From 10.10.100.5:1298 at 2589
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 10.10.100.10
From: 4444<sip:4444@10.10.100.10:5060>;tag=41165572a1d
To: 1234<sip:1234@10.10.100.5:8982>;tag=08ca52fc-4b12-4f11-a101-55fbc433e3b1
Call-ID: Excel-CSP255.1014.2589.0@10.10.100.10
CSeq: 1 INVITE
User-Agent: Windows RTC/1.0
Content-Length: 0
5 -RECEIVED From 10.10.100.5:1298 at 2589
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 10.10.100.10
From: 4444<sip:4444@10.10.100.10:5060>;tag=41165572a1d
To: 1234<sip:1234@10.10.100.5:8982>;tag=08ca52fc-4b12-4f11-a101-55fbc433e3b1
Call-ID: EXCEL-CSP255.1014.2589.0@10.10.100.10
CSeq: 1 INVITE
User-Agent: Windows RTC/1.0
Content-Length: 0
6 -SENT To 10.10.100.40:5060 at 2589
SIP/2.0 180 Ringing
To: sip:1234@10.10.100.10;tag=4206a1c
From: sip:4444@10.10.100.10;tag=1c29051
Call-ID: call-973574993-5@10.10.100.40
CSeq: 1 INVITE
Contact: 1234<sip:1234@10.10.100.10:5060>
Via: SIP/2.0/UDP 10.10.100.40
User-Agent: Excel/82.0.66
Content-Length: 0
7 -RECEIVED From 10.10.100.5:1298 at 2592
SIP/2.0 200 OK
Via: SIP/2.0/UDP 10.10.100.10
From: 4444<sip:4444@10.10.100.10:5060>;tag=41165572a1d
To: 1234<sip:1234@10.10.100.5:8982>;tag=08ca52fc-4b12-4f11-a101-55fbc433e3b1
Call-ID: EXCEL-CSP255.1014.2589.0@10.10.100.10
CSeq: 1 INVITE
Contact: <sip:10.10.100.5:8982>
User-Agent: Windows RTC/1.0
Content-Type: application/sdp
Content-Length: 159
v=0
o=vrao 0 0 IN IP4 10.10.100.5
s=SIP_Call
c=IN IP4 10.10.100.5
b=CT:1000
t=0 0
m=audio 36400 RTP/AVP 0 8
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
8 -SENT To 10.10.100.5:8982 at 2592
ACK sip:10.10.100.5:8982 SIP/2.0
Via: SIP/2.0/UDP 10.10.100.10
To: 1234<sip:1234@10.10.100.5:8982>;tag=08ca52fc-4b12-4f11-a101-55fbc433e3b1
From: 4444<sip:4444@10.10.100.10:5060>;tag=41165572a1d
Call-ID: EXCEL-CSP255.1014.2589.0@10.10.100.10
CSeq: 1 ACK
Content-Length: 0
9 -SENT To 10.10.100.40:5060 at 2593
SIP/2.0 200 OK
To: sip:1234@10.10.100.10;tag=4206a1c
From: sip:4444@10.10.100.10;tag=1c29051
Call-ID: call-973574993-5@10.10.100.40
CSeq: 1 INVITE
Contact: 1234<sip:1234@10.10.100.10:5060>
Require: timer
Supported: timer
Session-Expires: 1800; refresher=uas
Via: SIP/2.0/UDP 10.10.100.40
User-Agent: Excel/82.0.66
Content-Type: application/sdp
Content-Length: 165
v=0
o=sip 946687393 946687393 IN IP4 10.10.100.10
s=SIP_Call
c=IN IP4 10.10.100.5
t=0 0
m=audio 36400 RTP/AVP 0 8
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
10-RECEIVED From 10.10.100.40:1028 at 2593
ACK sip:1234@10.10.100.10:5060 SIP/2.0
Contact: sip:4444@10.10.100.40
From: sip:4444@10.10.100.10;tag=1c29051
To: sip:1234@10.10.100.10;tag=4206a1c
Call-Id: call-973574993-5@10.10.100.40
Cseq: 1 ACK
Session-Expires: 1800
Accept-Language: en
User-Agent: Pingtel/1.2.6 (VxWorks)
Via: SIP/2.0/UDP 10.10.100.40
Content-Length: 0