Sure you can. Take a look at header manipulation with pseudovariankes and http_client module in 
https://www.kamailio.org/docs/modules/stable/modules/http_client.html

You can start with the default config and take it from there.

If you don’t know kamailio at all, don’t be afraid to ask here for help.

You may also be interested in 
https://www.kamailio.org/dokuwiki/doku.php and there’s a couple of videos there.

Good luck!

David

On Tue, 19 Jan 2021 at 20:50, Mark Lawrence <marklawrence@hotmail.co.uk> wrote:

Hi All,

 

Sorry for the intrusion and asking directly, but there’s so much information out there that I would spend years looking for the answer myself and spending equal amount of time in a lab playing. I do like the last idea but time is a little short.

 

I’m thinking of using Kamailio to overcome a few downfalls in the main SBC/PBX commercial product space that I’ve typically deployed and wanted to ask if it is possible to use as a stateful proxy and carry out the following header manipulation type scenario with a bit more dynamassium:

 

Use the FROM and TO header to create two value pairs that would be sent via a REST request to an external application, which will return two corresponding values to (a) supply a different value to update the original FROM header and (b) a full PAI sting to add on to the outgoing message.

 

If you have experience of this or if it’s a nonstarter I’d love to know.

 

There’s so many modules and great stuff that you have in your toy chest it is amazing and kudos to all you developers being so inventive out there: it leaves me to think I’ve been deploying SIP wrong all these years.

 

Thanks and keep safe and well, Mark

 

_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
--
Regards,

David Villasmil
email: david.villasmil.work@gmail.com
phone: +34669448337