Pjsip show registration

Does it mean that Inbound and outbound are 2 separate registrations? and with different name/sections? and can’t we have same for IN and OUT

Endpoint: INPRO
InAuth: INPRO-auth/pjsip2sun
Aor: INPRO-aor
Transport: transport-udp

Endpoint: mytrunk
OutAuth: provider_auth/pjsip2sun
Aor: mytrunk
Contact: mytrunk/sip:
Identify: mytrunk/mytrunk

May be my question is not 100% correct because I am a newbie in pjsip, please help

I don’t understand quite what you mean. Accepting incoming registrations and doing outbound registrations are two separate things in both chan_sip and chan_pjsip. The endpoints can’t have the same name.

Yes, you are right but I am confused on what the command is showing on InAuth & OutAuth on outbound registration?.

InAuth is the authentication credentials used for inbound calls/registration, OutAuth is the authentication credentials used for outbound calls.

Ok, It means they are configured correctly as shown?

I can’t answer that as I don’t know what your setup is like.

Ok, let me tell you how I want to setup.

I have
Two ITSP -> P1 & P2
Two Endpoints(Peers) -> C1 & C2

I want when call comes in from P1 then call should go to C1 and vice versa for outbound calls
same case should happen with P2 & C2

is it possible?

Yes, there are already individuals who do this. You might find it easier to use wizards[1] instead.

[1] https://wiki.asterisk.org/wiki/display/AST/PJSIP+Configuration+Wizard

It says Both produce the same result. so why should we use pjsip instead of wizard? and if wizard can work so can we use it in realtime?

Wizards don’t currently work in realtime, they are used to simplify the configuration. If you need realtime then you’ll have to stick to the normal way.

Ok, Thanks for helping me