LiquidFiles Documentation
LiquidFiles Documentation

SMS Delivery Actionscript

SMS Delivery Actionscript adds custom delivery for SMS tokens. You can use this if your SMS provider uses HTTP POSTS or other more complex configurations than what's possibly using a simple HTTP GET request that's builtin to LiquidFiles as standard.

You can install or upload scripts by going to Admin → Configuration → Actionscripts. Please see the Actionscript Installation instruction for more details. When you have installed the script, you can enable the SMS Delivery Actionscript in Admin → Configuration → Strong Auth SMS.

When the script is executed, it will be executed like:

your_actionscript.ext phonenumber token

So the first argument passed to the script is the users phone number and the second is the random token. Any additional messages or anything like that, you will need to add yourself in the script.

Example Actionscripts

Please see the following examples Actionscript that will send a SMS using Clicksends API with a HTTP POST SMS API


# fill in your Clicksend's base64 authentication header
# (encode base64 ClicksendApiUsername:ClicksendApiKey)

message="LiquidFiles 2FA Token $2"

/usr/bin/curl -s -X POST --header "Authorization: Basic $CLICKSEND_AUTH" "$phone_number&message=$message" SMS API


# type your TWILIO attributes

message="LiquidFiles 2FA Token $2"

/usr/bin/curl -X POST$TWILIO_ACCOUNT_SID/Messages.json \
  --data-urlencode "Body=$message" \
  --data-urlencode "From=+$TWILIO_FROM_PHONE" \
  --data-urlencode "To=+$phone_number" \