HTTP Request from within the core
Hi, are there any ready-to-use core commands (to use in a c module ) to make http requests ? regards, gerald weber
You can use the API for curl or just check how the codebase for curl works: http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/ Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/ -Avi
Thanks, looks very easy to implement. Just on more question: I need to get the IP address of a registered user. E.g. user/2000 is a SNOM with ip 192.168.20.219 I guess a query against the registrations table ist the fastest way to do this ? Or is there any core api command ? Thanks Von: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] Im Auftrag von Avi Marcus Gesendet: Mittwoch, 25. Juli 2012 14:26 An: FreeSWITCH Users Help Betreff: Re: [Freeswitch-users] HTTP Request from within the core You can use the API for curl or just check how the codebase for curl works: http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/ Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/ -Avi
sofia_contact might be what you are looking for. Brian Foster Endigo Computer LLC Sent from a mobile device. On Jul 25, 2012 9:04 AM, "Gerald Weber" <gerald.weber@besharp.at> wrote:
Thanks, looks very easy to implement.****
** **
Just on more question:****
I need to get the IP address of a registered user.****
E.g. user/2000 is a SNOM with ip 192.168.20.219****
I guess a query against the registrations table ist the fastest way to do this ?****
Or is there any core api command ? ****
** **
Thanks****
** **
** **
*Von:* freeswitch-users-bounces@lists.freeswitch.org [mailto: freeswitch-users-bounces@lists.freeswitch.org] *Im Auftrag von *Avi Marcus *Gesendet:* Mittwoch, 25. Juli 2012 14:26 *An:* FreeSWITCH Users Help *Betreff:* Re: [Freeswitch-users] HTTP Request from within the core****
** **
You can use the API for curl or just check how the codebase for curl works: ****
http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/ ****
Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/****
** **
-Avi****
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
Join Us At ClueCon - Aug 7-9, 2012
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Thats it, muchas gracias ! Von: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] Im Auftrag von Brian Foster Gesendet: Mittwoch, 25. Juli 2012 15:10 An: FreeSWITCH Users Help Betreff: Re: [Freeswitch-users] HTTP Request from within the core sofia_contact might be what you are looking for. Brian Foster Endigo Computer LLC Sent from a mobile device. On Jul 25, 2012 9:04 AM, "Gerald Weber" <gerald.weber@besharp.at<mailto:gerald.weber@besharp.at>> wrote: Thanks, looks very easy to implement. Just on more question: I need to get the IP address of a registered user. E.g. user/2000 is a SNOM with ip 192.168.20.219 I guess a query against the registrations table ist the fastest way to do this ? Or is there any core api command ? Thanks Von: freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org> [mailto:freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org>] Im Auftrag von Avi Marcus Gesendet: Mittwoch, 25. Juli 2012 14:26 An: FreeSWITCH Users Help Betreff: Re: [Freeswitch-users] HTTP Request from within the core You can use the API for curl or just check how the codebase for curl works: http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/ Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/ -Avi _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org<mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com Join Us At ClueCon - Aug 7-9, 2012 FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
It sounds like you might be doing something similar to what mod_snom started with. I've worked heavily with phone automation and I would be curious which phones you're working with and your experiences with them. Here's an example I was working on to automate the testing of Polycom BLF lights and call scenarios: http://imgur.com/a/9JfcR William King Senior Engineer Quentus Technologies, INC 1037 NE 65th St Suite 273 Seattle, WA 98115 Main: (877) 211-9337 Office: (206) 388-4772 Cell: (253) 686-5518 william.king@quentustech.com On 07/25/2012 06:47 AM, Gerald Weber wrote:
Thats it, muchas gracias !
*Von:*freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] *Im Auftrag von *Brian Foster *Gesendet:* Mittwoch, 25. Juli 2012 15:10 *An:* FreeSWITCH Users Help *Betreff:* Re: [Freeswitch-users] HTTP Request from within the core
sofia_contact might be what you are looking for.
Brian Foster Endigo Computer LLC
Sent from a mobile device.
On Jul 25, 2012 9:04 AM, "Gerald Weber" <gerald.weber@besharp.at <mailto:gerald.weber@besharp.at>> wrote:
Thanks, looks very easy to implement.
Just on more question:
I need to get the IP address of a registered user.
E.g. user/2000 is a SNOM with ip 192.168.20.219
I guess a query against the registrations table ist the fastest way to do this ?
Or is there any core api command ?
Thanks
*Von:*freeswitch-users-bounces@lists.freeswitch.org <mailto:freeswitch-users-bounces@lists.freeswitch.org> [mailto:freeswitch-users-bounces@lists.freeswitch.org <mailto:freeswitch-users-bounces@lists.freeswitch.org>] *Im Auftrag von *Avi Marcus *Gesendet:* Mittwoch, 25. Juli 2012 14:26 *An:* FreeSWITCH Users Help *Betreff:* Re: [Freeswitch-users] HTTP Request from within the core
You can use the API for curl or just check how the codebase for curl works:
http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/
Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/
-Avi
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org <mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
Join Us At ClueCon - Aug 7-9, 2012
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org <mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
Join Us At ClueCon - Aug 7-9, 2012
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Wow,cool idea to test the leds this way ! But my goal is a different: I need a way to tell a snom phone to pickup or hangup a call using a (agent) webinterface. With PhonerLite this is easy, just send uuid_phone_event uuid talk and you are done, but snom doesn't accept a NOTIFY talk event. They offer a way to simulate a keypress using http requests (e.g. "/command.htm?key=ENTER" ). My idea is to patch this functionality into mod_snom. The other way: Let uuid_phone_event decide what to send by looking up the user_agent in the sip_registration table. (I dont like this one, because this means i have to patch every phone specific handling into the core. But it would be a nicer way for me to build my webinterface.) gw Von: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] Im Auftrag von William King Gesendet: Freitag, 27. Juli 2012 08:54 An: freeswitch-users@lists.freeswitch.org Betreff: Re: [Freeswitch-users] HTTP Request from within the core It sounds like you might be doing something similar to what mod_snom started with. I've worked heavily with phone automation and I would be curious which phones you're working with and your experiences with them. Here's an example I was working on to automate the testing of Polycom BLF lights and call scenarios: http://imgur.com/a/9JfcR William King Senior Engineer Quentus Technologies, INC 1037 NE 65th St Suite 273 Seattle, WA 98115 Main: (877) 211-9337 Office: (206) 388-4772 Cell: (253) 686-5518 william.king@quentustech.com<mailto:william.king@quentustech.com> On 07/25/2012 06:47 AM, Gerald Weber wrote: Thats it, muchas gracias ! Von: freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org> [mailto:freeswitch-users-bounces@lists.freeswitch.org] Im Auftrag von Brian Foster Gesendet: Mittwoch, 25. Juli 2012 15:10 An: FreeSWITCH Users Help Betreff: Re: [Freeswitch-users] HTTP Request from within the core sofia_contact might be what you are looking for. Brian Foster Endigo Computer LLC Sent from a mobile device. On Jul 25, 2012 9:04 AM, "Gerald Weber" <gerald.weber@besharp.at<mailto:gerald.weber@besharp.at>> wrote: Thanks, looks very easy to implement. Just on more question: I need to get the IP address of a registered user. E.g. user/2000 is a SNOM with ip 192.168.20.219 I guess a query against the registrations table ist the fastest way to do this ? Or is there any core api command ? Thanks Von: freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org> [mailto:freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org>] Im Auftrag von Avi Marcus Gesendet: Mittwoch, 25. Juli 2012 14:26 An: FreeSWITCH Users Help Betreff: Re: [Freeswitch-users] HTTP Request from within the core You can use the API for curl or just check how the codebase for curl works: http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/ Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/ -Avi _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org<mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com Join Us At ClueCon - Aug 7-9, 2012 FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org _________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org<mailto:consulting@freeswitch.org> http://www.freeswitchsolutions.com FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com Join Us At ClueCon - Aug 7-9, 2012 FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Ya and seven is working on that a bit. If we build some momentum we can get it working. On Jul 27, 2012 5:24 AM, "Gerald Weber" <gerald.weber@besharp.at> wrote:
Wow,cool idea to test the leds this way !****
** **
But my goal is a different:****
I need a way to tell a snom phone to pickup or hangup a call using a (agent) webinterface.****
With PhonerLite this is easy, just send uuid_phone_event uuid talk and you are done, but snom doesn’t accept a NOTIFY talk event.****
They offer a way to simulate a keypress using http requests (e.g. „/command.htm?key=ENTER“ ). My idea is to patch this functionality into mod_snom.****
** **
The other way:****
Let uuid_phone_event decide what to send by looking up the user_agent in the sip_registration table.****
(I dont like this one, because this means i have to patch every phone specific handling into the core. But it would be a nicer way for me to build my webinterface.)****
** **
gw****
** **
** **
*Von:* freeswitch-users-bounces@lists.freeswitch.org [mailto: freeswitch-users-bounces@lists.freeswitch.org] *Im Auftrag von *William King *Gesendet:* Freitag, 27. Juli 2012 08:54 *An:* freeswitch-users@lists.freeswitch.org *Betreff:* Re: [Freeswitch-users] HTTP Request from within the core****
** **
It sounds like you might be doing something similar to what mod_snom started with. I've worked heavily with phone automation and I would be curious which phones you're working with and your experiences with them.
Here's an example I was working on to automate the testing of Polycom BLF lights and call scenarios: http://imgur.com/a/9JfcR
****
William King****
Senior Engineer****
Quentus Technologies, INC****
1037 NE 65th St Suite 273****
Seattle, WA 98115****
Main: (877) 211-9337****
Office: (206) 388-4772****
Cell: (253) 686-5518****
william.king@quentustech.com ****
On 07/25/2012 06:47 AM, Gerald Weber wrote: ****
Thats it, muchas gracias !****
****
*Von:* freeswitch-users-bounces@lists.freeswitch.org [ mailto:freeswitch-users-bounces@lists.freeswitch.org<freeswitch-users-bounces@lists.freeswitch.org>] *Im Auftrag von *Brian Foster *Gesendet:* Mittwoch, 25. Juli 2012 15:10 *An:* FreeSWITCH Users Help *Betreff:* Re: [Freeswitch-users] HTTP Request from within the core****
****
sofia_contact might be what you are looking for. ****
Brian Foster Endigo Computer LLC****
Sent from a mobile device.****
On Jul 25, 2012 9:04 AM, "Gerald Weber" <gerald.weber@besharp.at> wrote:** **
Thanks, looks very easy to implement.****
****
Just on more question:****
I need to get the IP address of a registered user.****
E.g. user/2000 is a SNOM with ip 192.168.20.219****
I guess a query against the registrations table ist the fastest way to do this ?****
Or is there any core api command ? ****
****
Thanks****
****
****
*Von:* freeswitch-users-bounces@lists.freeswitch.org [mailto: freeswitch-users-bounces@lists.freeswitch.org] *Im Auftrag von *Avi Marcus *Gesendet:* Mittwoch, 25. Juli 2012 14:26 *An:* FreeSWITCH Users Help *Betreff:* Re: [Freeswitch-users] HTTP Request from within the core****
****
You can use the API for curl or just check how the codebase for curl works: ****
http://wiki.freeswitch.org/wiki/Mod_curl -- src/mod/applications/mod_curl/ ****
Or look at http://wiki.freeswitch.org/wiki/Mod_http_cache -- src/mod/applications/mod_http_cache/****
****
-Avi****
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
Join Us At ClueCon - Aug 7-9, 2012
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org****
****
_________________________________________________________________________****
Professional FreeSWITCH Consulting Services:****
consulting@freeswitch.org****
http://www.freeswitchsolutions.com****
** **
FreeSWITCH-powered IP PBX: The CudaTel Communication Server****
** **
Official FreeSWITCH Sites****
http://wiki.freeswitch.org****
** **
Join Us At ClueCon - Aug 7-9, 2012****
** **
FreeSWITCH-users mailing list****
FreeSWITCH-users@lists.freeswitch.org****
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users****
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users****
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
Join Us At ClueCon - Aug 7-9, 2012
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
participants (5)
-
Anthony Minessale
-
Avi Marcus
-
Brian Foster
-
Gerald Weber
-
William King