Helmut Wolf wrote: > Hi Benny, > > First I wish you and your team a happy new year and I would like to thank you for the very good support! Thanks for kind kind words! :) > I am using PJSIP for an stateful proxy which also acts as an Registar (self implemented). > How can I use pjsip to route incoming and outgoing calls? Pjsua uses dialogs with invite sessions but how can I realize this with > stateful proxy? There are no dialogs, only transactions. I need to know when a call is pending, established and terminated (BYE, > CANCEL, session timeout,...). Yeah this is the problem with stateful proxies in general, as they are only transaction stateful and not call stateful. If you want it to record call states, then either you reimplement the call state progression logic in the stateful proxy, or implement a B2BUA instead. Both approaches have their pros and cons. I know people from both the well known open source B2BUA and SIP proxy camps are here on this list, maybe they can shed some light (I know who you are ;-) ). cheers, -benny > Best regards, > > Helmut Wolf