Overview
Icon for Twilio

Twilio

Send SMS and voice notifications with Twilio

Twilio SMS

Utilize Twilio's SMS APIs to send customers SMS notifications.

Twilio SMS Plugin Documentation | Medusa Website | Medusa Repository

Features

  • Access Twilio's SMS APIs easily using the Copy to clipboardTwilioSmsService.

Prerequisites

How to Install

1. Run the following command in the directory of the Medusa backend:

npm install medusa-plugin-twilio-sms

2. Set the following environment variable in Copy to clipboard.env:

TWILIO_SMS_ACCOUNT_SID=<YOUR_ACCOUNT_SID>
TWILIO_SMS_AUTH_TOKEN=<YOUR_AUTH_TOKEN>
TWILIO_SMS_FROM_NUMBER=<YOUR_TWILIO_NUMBER>

3. In Copy to clipboardmedusa-config.js add the following at the end of the Copy to clipboardplugins array:

const plugins = [
// ...
{
resolve: `medusa-plugin-twilio-sms`,
options: {
account_sid: process.env.TWILIO_SMS_ACCOUNT_SID,
auth_token: process.env.TWILIO_SMS_AUTH_TOKEN,
from_number: process.env.TWILIO_SMS_FROM_NUMBER,
},
},
]

Test the Plugin

In your code, use the Copy to clipboardTwilioSmsService where necessary to send your customers notifications.

Additional Resources

You may also like

Browse all integrations

Build your own

Develop your own custom integraiton

Build your own integration with our API to speed up your processes. Make your integration available via npm for it to be shared in our Library with the broader Medusa community.

gift card interface

Ready to build your custom commerce setup?