Topics   All   MacOS (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server   Client   Old   Deprecated   Guides   Examples   Videos
New in version: 11.3   11.4   11.5   12.0   12.1   12.2   12.3   12.4   12.5   13.0    Statistic    FMM    Blog  

WebHook.Listen

Starts listening for incoming requests on this port.

Component Version macOS Windows Linux Server iOS SDK
WebHook 11.5 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "WebHook.Listen"; WebHook; Port )   More

Parameters

Parameter Description Example
WebHook The reference number of the web hook. $webhook
Port The port number to use.
Between 1024 and 65535.

Can be zero to pick random port (since v12.5)
9999

Result

Returns OK or error.

Description

Starts listening for incoming requests on this port.
You may need to allow incoming connections for FileMaker application in your firewall application.

The queue for incoming connections waiting to be accepted by the plugin is currently 10.

Examples

Listen on port 9999:

Set Variable [ $r ; Value: MBS("WebHook.Listen"; $$WebHooks; 9999) ]

Listen on new port:

Set Variable [ $$WebHooks ; Value: MBS("WebHook.Create") ]
Set Field [ WebHook::Server Webhook ; $$WebHooks ]
# ask for new random port
Set Variable [ $r ; Value: MBS("WebHook.Listen"; $$WebHooks; 0) ]
# set trigger script
Set Variable [ $r ; Value: MBS("WebHook.SetScript"; $$WebHooks; Get(FileName); "WebHookReceived") ]
# query port
Set Field [ WebHook::Server Port ; MBS( "WebHook.GetPort"; $$WebHooks ) ]

See also

Release notes

Example Databases

Blog Entries

Created 13th October 2021, last changed 30th September 2022


WebHook.List - WebHook.Release

Feedback: Report problem or ask question.


Start Chat