How to show PJSIP User-Agent

Hi,
Is there anyway that showing user-agent in PJSIP.
In SIP when I use sip show peer I could show user-agent.

pjsip list endpoints

for a comple list of pjsip commands

asterisk -x " core show help" | grep -i pj

Hi,

I have checked but I couldn’t find.

root@asterisk-dominicana:~# asterisk -x " pjsip list endpoints"

Endpoint: <Endpoint/CID…> <State…> <Channels.>

Endpoint: 6001 Unavailable 0 of inf
Endpoint: 6002 Unavailable 0 of inf

Where is the User-Agent for example, Yealink or Avaya,

if you mean SIP user agent identification strings

Every SIP user agent (phone, software, device) identifies itself with a string. The syntax of this string is not defined, but a common practise is

http://www.voip-info.org/wiki/view/SIP+user+agent+identification

There’s not a CLI tool for that, but it can be obtained using the PJSIP_CONTACT dialplan function:

https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Function_PJSIP_CONTACT

Cheers

2 Likes

You may use the Asterisk database for it

/registrar/contact/2038;@f8d94c15f84f86711d74773c634317d1: {"via_addr":"192.168.31.59","qualify_timeout":"3.000000","call_id":"1864024792@192.168.31.59","reg_server":"","prune_on_boot":"no","path":"","endpoint":"2038","via_port":"5062","authenticate_qualify":"no","uri":"sip:2038@192.168.31.59:5062","qualify_frequency":"30","user_agent":"VP530P 23.70.0.40","expiration_time":"1584137684","outbound_proxy":""}