|
@@ -14,27 +14,26 @@ Juha Heinanen
|
|
|
|
|
|
Copyright © 2006 voice-system.ro
|
|
|
Revision History
|
|
|
- Revision $Revision$ $Date: 2008-08-06 12:08:33 +0200
|
|
|
- (Mi, 06 Aug 2008) $
|
|
|
- __________________________________________________________
|
|
|
+ Revision $Revision$ $Date$
|
|
|
+ __________________________________________________________________
|
|
|
|
|
|
Table of Contents
|
|
|
|
|
|
1. Admin Guide
|
|
|
|
|
|
- 1.1. Overview
|
|
|
- 1.2. Dependencies
|
|
|
+ 1. Overview
|
|
|
+ 2. Dependencies
|
|
|
|
|
|
- 1.2.1. Kamailio Modules
|
|
|
- 1.2.2. External Libraries or Applications
|
|
|
+ 2.1. Kamailio Modules
|
|
|
+ 2.2. External Libraries or Applications
|
|
|
|
|
|
- 1.3. Exported Parameters
|
|
|
- 1.4. Exported Functions
|
|
|
- 1.5. Exported MI functions
|
|
|
+ 3. Exported Parameters
|
|
|
+ 4. Exported Functions
|
|
|
+ 5. Exported MI functions
|
|
|
|
|
|
- 1.5.1. pua_publish
|
|
|
+ 5.1. pua_publish
|
|
|
|
|
|
- 1.6. pua_subscribe
|
|
|
+ 6. pua_subscribe
|
|
|
|
|
|
List of Examples
|
|
|
|
|
@@ -42,44 +41,63 @@ Juha Heinanen
|
|
|
|
|
|
Chapter 1. Admin Guide
|
|
|
|
|
|
-1.1. Overview
|
|
|
+ Table of Contents
|
|
|
+
|
|
|
+ 1. Overview
|
|
|
+ 2. Dependencies
|
|
|
+
|
|
|
+ 2.1. Kamailio Modules
|
|
|
+ 2.2. External Libraries or Applications
|
|
|
+
|
|
|
+ 3. Exported Parameters
|
|
|
+ 4. Exported Functions
|
|
|
+ 5. Exported MI functions
|
|
|
+
|
|
|
+ 5.1. pua_publish
|
|
|
+
|
|
|
+ 6. pua_subscribe
|
|
|
|
|
|
- The pua_mi offers the possibility to publish presence
|
|
|
- information and subscribe to presence information via MI
|
|
|
- transports.
|
|
|
+1. Overview
|
|
|
|
|
|
- Using this module you can create independent
|
|
|
- applications/scripts to publish not sip-related information
|
|
|
- (e.g., system resources like CPU-usage, memory, number of
|
|
|
- active subscribers ...). Also, this module allows non-SIP
|
|
|
- speaking applications to subscribe presence information kept in
|
|
|
- a SIP presence server.
|
|
|
+ The pua_mi offers the possibility to publish presence information and
|
|
|
+ subscribe to presence information via MI transports.
|
|
|
|
|
|
-1.2. Dependencies
|
|
|
+ Using this module you can create independent applications/scripts to
|
|
|
+ publish not sip-related information (e.g., system resources like
|
|
|
+ CPU-usage, memory, number of active subscribers ...). Also, this module
|
|
|
+ allows non-SIP speaking applications to subscribe presence information
|
|
|
+ kept in a SIP presence server.
|
|
|
|
|
|
-1.2.1. Kamailio Modules
|
|
|
+2. Dependencies
|
|
|
+
|
|
|
+ 2.1. Kamailio Modules
|
|
|
+ 2.2. External Libraries or Applications
|
|
|
+
|
|
|
+2.1. Kamailio Modules
|
|
|
|
|
|
The following modules must be loaded before this module:
|
|
|
* pua
|
|
|
|
|
|
-1.2.2. External Libraries or Applications
|
|
|
+2.2. External Libraries or Applications
|
|
|
|
|
|
- The following libraries or applications must be installed
|
|
|
- before running Kamailio with this module loaded:
|
|
|
+ The following libraries or applications must be installed before
|
|
|
+ running Kamailio with this module loaded:
|
|
|
* none
|
|
|
|
|
|
-1.3. Exported Parameters
|
|
|
+3. Exported Parameters
|
|
|
|
|
|
* none
|
|
|
|
|
|
-1.4. Exported Functions
|
|
|
+4. Exported Functions
|
|
|
+
|
|
|
+ The module does not export functions to be used in configuration
|
|
|
+ script.
|
|
|
|
|
|
- The module does not export functions to be used in
|
|
|
- configuration script.
|
|
|
+5. Exported MI functions
|
|
|
|
|
|
-1.5. Exported MI functions
|
|
|
+ 5.1. pua_publish
|
|
|
|
|
|
-1.5.1. pua_publish
|
|
|
+5.1. pua_publish
|
|
|
|
|
|
Command parameters:
|
|
|
* presentity_uri - e.g. sip:[email protected]
|
|
@@ -88,13 +106,18 @@ Chapter 1. Admin Guide
|
|
|
information (e.g. presence).
|
|
|
* content type - Content type of published information (e.g.
|
|
|
application/pidf+xml) or . if no information is enclosed.
|
|
|
- * ETag - ETag that publish should match or . if no ETag is
|
|
|
- given.
|
|
|
- * extra_headers - Extra headers added to PUBLISH request or .
|
|
|
- if no extra headers.
|
|
|
+ * id - id for a series of related PUBLISHes to the same
|
|
|
+ presentity-uri or . to always use the same series. For example
|
|
|
+ dialog-info must reuse the same id for the same call otherwise
|
|
|
+ status will be lost when multiple parallel calls to/from the same
|
|
|
+ user take place. The dialog-id from the dialog-info body qualifies
|
|
|
+ as a suitable id here.
|
|
|
+ * ETag - ETag that publish should match or . if no ETag is given.
|
|
|
+ * extra_headers - Extra headers added to PUBLISH request or . if no
|
|
|
+ extra headers.
|
|
|
* body - The body of the publish request containing published
|
|
|
- information or missing if no published information. It has
|
|
|
- to be a single line for FIFO transport.
|
|
|
+ information or missing if no published information. It has to be a
|
|
|
+ single line for FIFO transport.
|
|
|
|
|
|
Example 1.1. pua_publish FIFO example
|
|
|
...
|
|
@@ -106,20 +129,19 @@ presence
|
|
|
application/pidf+xml
|
|
|
.
|
|
|
.
|
|
|
-<?xml version='1.0'?><presence xmlns='urn:ietf:params:xml:ns:pidf' xmlns
|
|
|
-:dm='urn:ietf:params:xml:ns:pidf:data-model' xmlns:rpid='urn:ietf:params
|
|
|
-:xml:ns:pidf:rpid' xmlns:c='urn:ietf:params:xml:ns:pidf:cipid' entity='s
|
|
|
[email protected]'><tuple id='0x81475a0'><status><basic>open</basic></s
|
|
|
-tatus></tuple><dm:person id='pdd748945'><rpid:activities><rpid:away/>awa
|
|
|
-y</rpid:activities><dm:note>CPU:16 MEM:476</dm:note></dm:person></presen
|
|
|
-ce>
|
|
|
-
|
|
|
+.
|
|
|
+<?xml version='1.0'?><presence xmlns='urn:ietf:params:xml:ns:pidf' xmlns:dm='urn
|
|
|
+:ietf:params:xml:ns:pidf:data-model' xmlns:rpid='urn:ietf:params:xml:ns:pidf:rpi
|
|
|
+d' xmlns:c='urn:ietf:params:xml:ns:pidf:cipid' entity='[email protected]'><tup
|
|
|
+le id='0x81475a0'><status><basic>open</basic></status></tuple><dm:person id='pdd
|
|
|
+748945'><rpid:activities><rpid:away/>away</rpid:activities><dm:note>CPU:16 MEM:4
|
|
|
+76</dm:note></dm:person></presence>
|
|
|
|
|
|
-1.6. pua_subscribe
|
|
|
+6. pua_subscribe
|
|
|
|
|
|
Command parameters:
|
|
|
* presentity_uri - e.g. sip:[email protected]
|
|
|
* watcher_uri - e.g. sip:[email protected]
|
|
|
* event package
|
|
|
- * expires - Relative time in seconds for the desired validity
|
|
|
- of the subscription.
|
|
|
+ * expires - Relative time in seconds for the desired validity of the
|
|
|
+ subscription.
|