Chan.connect

From Yate Documentation
(Difference between revisions)
Jump to: navigation, search
(Created page with " '''chan.connect''' is a message sent by a module requesting the connection of two channels. ===Parameters=== ;id : Specify channel id of leg A ;targetid : Specify the chann...")
 
(Return)
Line 15: Line 15:
 
===Return===
 
===Return===
  
A module processing this message should return true if the connection succeedded
+
A module processing this message should return true if the connection succeedded.
  
 
===Example===
 
===Example===

Revision as of 11:19, 19 October 2012

chan.connect is a message sent by a module requesting the connection of two channels.

Parameters

id
Specify channel id of leg A
targetid
Specify the channel id of leg B
id_peer
If true, field id will be treated as peer, false - as id
targetid_peer
Boolean value indicating to connect the corresponding peer. Defaults to false. If true, field id will be treated as peer of provided call id, false - as id itself.

Return

A module processing this message should return true if the connection succeedded.

Example

Initiate call to two persons and connect them to each other

%%>message:0xb59f6f11.327305252:1326117799:call.execute::callto=dumb/:target=person1

Answer:

%%<message:0xb59f6f11.327305252:true:call.execute::callto=dumb/:target=person1:id=dumb/47:peerid=sip/134:targetid=sip/134


Call to person2, connect it to dumb channel:

%%>message:0xb59f6f11.327305253:1326117800:call.execute::callto=dumb/:target=person2

Answer:

%%<message:0xb59f6f11.327305253:true:call.execute::callto=dumb/:target=person2:id=dumb/48:peerid=sip/135:targetid=sip/135


Next, connect them:

%%>message:0xb59f6f11.327305254:1326117801:chan.connect::id=sip/134:targetid=sip/135

Or:

%%>message:0xb59f6f11.327305254:1326117801:chan.connect::id=dumb/47:id_peer=true:targetid=dumb/48:targetid_peer=true
Personal tools
Namespaces

Variants
Actions
Preface
Configuration
Administrators
Developers