User Tools

Site Tools


cookbooks:devel:pseudovariables

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
cookbooks:devel:pseudovariables [2018/03/21 15:13]
miconda [$C(xy) - Foreground and background colors]
cookbooks:devel:pseudovariables [2018/07/20 18:03]
miconda [$hdr(name) - Headers]
Line 490: Line 490:
 **$Rut** - local socket where the SIP messages was received in URI format, always with transport parameter. **$Rut** - local socket where the SIP messages was received in URI format, always with transport parameter.
  
 +==== $sas - Source address in socket format ====
 +
 +**$sas** - get source address in socket format (proto:address:port).
 ==== $sbranch(attr) - Static Branch ==== ==== $sbranch(attr) - Static Branch ====
  
Line 519: Line 522:
 **$si** - reference to IP source address of the message - see also $siz **$si** - reference to IP source address of the message - see also $siz
  
 +==== $sid - Server ID ====
 +
 +**$sid** - the value for server id (server_id parameter)
 ==== $siz - Source IP address ==== ==== $siz - Source IP address ====
  
Line 748: Line 754:
 **$(hdr(name)[N])** - represents the body of the N-th header identified by 'name'. **$(hdr(name)[N])** - represents the body of the N-th header identified by 'name'.
  
-If [N] is omitted then the body of the first header is printed. The first header is got when N=0, for the second N=1, a.s.o. In case of a comma-separated multi-body headers, it returns all the bodies, comma-separated. To print the last header of that type, use -1, or other negative values to count from the end. No white spaces are allowed inside the specifier (before }, before or after {, [, ] symbols). When N='*', all headers of that type are printed.+If [N] is omitted then the body of the first header is printed. The body of first header is returned when N=0, for the second N=1, a.s.o. In case of a comma-separated multi-body headers, it returns all the bodies, comma-separated. To print the last header of that type, use -1, or other negative values to count from the end. No white spaces are allowed inside the specifier (before }, before or after {, [, ] symbols). When N='*', all headers of that type are printed
 + 
 +If name is *, then any header name is matched, e.g., $hdr(*) is body of first header, $(hdr(*)[-1]) is body of last header.
  
 The module should identify compact header names. It is recommended to use dedicated specifiers for headers (e.g., $ua for user agent header), if they are available -- they are faster. The module should identify compact header names. It is recommended to use dedicated specifiers for headers (e.g., $ua for user agent header), if they are available -- they are faster.
cookbooks/devel/pseudovariables.txt · Last modified: 2022/04/11 15:24 by henningw