Twilio connector

The Twilio connector is used to integrate with an instance of Twilio to send SMS messages.

The Twilio connector is displayed on the process diagram with the Twilio logo.

Important: The TWilio connector requires a Twilio account to use. This account is separate to the Alfresco hosted environment and should be created and managed by customers.

Send SMS

The SEND_SMS action is used by the Twilio connector to send an SMS message.

The input parameters to send an SMS are:

ParameterTypeDescription
smsFromStringRequired. The phone number the SMS will be sent from.
smsToStringRequired. The list of numbers the SMS will be sent to.
smsBodyStringRequired. The contents of the SMS. The message supports Freemarker syntax, for example ${fullName.lastName} can be used from the metadata parameter to include variables.
metadataJSONOptional. Metadata to be used by the smsBody parameter to include process variables in a message.

The output parameters from sending an SMS using Twilio are:

ParameterTypeDescription
smsResultJSONOptional. An object containing a map of message IDs and destination numbers the message was sent to.

Configuration

An account ID and token are required by the connector to access Twilio. These are specific to your Twilio account and act as the authorization credentials.

The values are provided by Twilio when an account is created. They can also be located in the Twilio setup page.

Configuration parameters

The configuration parameters for the Slack connector are:

ParameterDescription
TWILIO_ACCOUNTRequired. Your account name obtained from Twilio.
TWILIO_TOKENRequired. A token for your account obtained from Twilio.

Errors

The possible errors that can be handled by the Twilio connector are:

ErrorDescription
MISSING_INPUTA mandatory input variable was not provided.
INVALID_INPUTThe input variable has an invalid type.
TWILIO_CONNECTION_ERRORUnable to connect to Twilio service.
AUTHENTICATION_CONNECTION_ERRORUnable to authenticate to Twilio.
INVALID_REQUEST_ERRORInvalid request.
INVALID_TO_PHONE_NUMBER_ERRORInvalid 'to' phone number.
INVALID_FROM_PHONE_NUMBER_ERRORInvalid 'from' phone number.
PERMISSION_DENIED_ERRORLack of permission to the resource and method requested.
INVALID_REGION_TO_PHONE_NUMBER_ERRORPermission to send an SMS has not been enabled for the region indicated by the 'To' number.
TEMPLATE_READ_ERRORCannot read the Freemarker template.
TEMPLATE_METADATA_ERRORThe template references non-existing metadata.
TEMPLATE_SYNTAX_ERRORInvalid Freemarker syntax.
UNKNOWN_ERRORUnexpected runtime error.
BAD_REQUESTThe server could not understand the request due to invalid syntax.
UNAUTHORIZEDThe request has not been applied because it lacks valid authentication.
FORBIDDENThe server understood the request but refuses to authorize it.
NOT_FOUNDThe server could not find what was requested.
METHOD_NOT_ALLOWEDThe request method is known by the server but is not supported.
NOT_ACCEPTABLEThe server cannot produce a response matching the list of acceptable values.
REQUEST_TIMEOUTThe server would like to shut down this unused connection.
CONFLICTThe request conflicts with current state of the server.
GONENo longer available.
UNPROCESSABLE_ENTITYThe server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions.
LOCKEDThe resource that is being accessed is locked.
FAILED_DEPENDENCYThe request failed due to failure of a previous request.
INTERNAL_SERVER_ERRORThe server has encountered a situation it doesn't know how to handle.
NOT_IMPLEMENTEDThe request method is not supported by the server and cannot be handled.
BAD_GATEWAYThe server got an invalid response.
SERVICE_UNAVAILABLEThe server is not ready to handle the request.
GATEWAY_TIMEOUTThe server is acting as a gateway and cannot get a response in time.

© 2023 Alfresco Software, Inc. All Rights Reserved.