Skip to content

[IMP] sms_marketing: add Twilio documentation #13909

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: 17.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions content/applications/marketing/sms_marketing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ rate)` outcomes.
Find out more about Odoo's SMS pricing, and check out some of the most frequently asked
questions.

.. card:: Twilio
:target: sms_marketing/twilio

In some countries with stricter regulations, the out-of-the-box solution proposed by Odoo
may not work. In this case, you can use our Twilio integration to send SMS worldwide.

SMS marketing dashboard
=======================

Expand Down Expand Up @@ -81,3 +87,4 @@ detailed analysis.
sms_marketing/marketing_campaigns
sms_marketing/mailing_lists_blacklists
sms_marketing/pricing_and_faq
sms_marketing/twilio
65 changes: 65 additions & 0 deletions content/applications/marketing/sms_marketing/twilio.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
==============
SMS via Twilio
==============

What is Twilio
==============

Twilio is a third-party provider that enables you to send SMS messages to your clients.
Odoo provides an easy way to use this service within your Odoo apps.

Why would I need it?
--------------------

Altough Odoo already comes with an out-of-the-box (IAP) solution for SMS messages, it might
not work in some countries with stricter legal requirements. Currently, Odoo registers
itself when possible to avoid extra setup for its customers, however in some countries
that is not enough and the client itself must do it. This can be done through Twilio.

Setup your Twilio account
=========================

By creating a Twilio account, you will be able to create a virtual phone number from
which you will be able to send SMS messages. These cost credits that are to be bought
on Twilio, not Odoo.

#. Go to `Twilio <https://www.twilio.com>`_
#. Sign up and create a Twilio account
#. Within your Twilio account, you can create multiple accounts (e.g. one for testing, one for each sub-company, etc.)
#. Create a new account

#. Enter the name, and select :guilabel:`Twilio` for the type
#. Select your :guilabel:`Billing Country` and click :guilabel:`Create new account`
#. Select the different options that match your needs

- For the :guilabel:`Twilio product`, select :guilabel:`SMS`
- For :guilabel:`How to build with Twilio`, select :guilabel:`With no code at all`
- For your :guilabel:`goal`, select :guilabel:`3rd party integrations`
#. Click on :guilabel:`Get Started with Twilio`
#. You account is now created, and you should arrive on your :guilabel:`Dashboard`
#. Go to :menuselection:`Phone Numbers --> Manage --> Buy a number`
#. Buy a number (it is a paying service, but you should have received some credits to start with)
#. Go back to bottom of the :guilabel:`Dashboard` page
#. Copy the :guilabel:`Account SID` and :guilabel:`Auth Token`

Beware that sending SMS to some countries (such as the US or Canada) might require a registration.
This can only be done by you, and not by Odoo. Please check out
`Twilio's Help Center <https://help.twilio.com>`_


Setup Odoo to use Twilio
========================

#. :ref:`Install <general/install>` the :guilabel:`Twilio SMS` module (`sms_twilio`)
#. In Odoo, go to :menuselection:`Settings --> General Settings --> Contacts --> Send SMS`,
select :guilabel:`Twilio` in the list of options, and save your change.
#. Go back to that option, and click :guilabel:`Manage Twilio Connection`
#. Paste the copied credentials accordingly
#. Click on :guilabel:`Reload numbers`
#. Your newly bought phone number should appear in the list
#. You can use the testing section to send an SMS

You can have multiple numbers (for instance once per country, or one per campaign), in that case,
you can reorder the numbers. By default, when sending an SMS to a client, Odoo will select the
number whose country is the same as the client. If none matches, Odoo will use the first number
available from the list respecting the order you have chosen.