Rate this page:

Assign Personal Phone Numbers to Salesforce Users

About Personal Phone Numbers

Personal numbers allow you to assign a dedicated phone number to an individual Salesforce user. By default, Twilio for Salesforce chooses a number in your messaging service for your Salesforce users to use.

With personal numbers, outbound messages from a Salesforce user are always sent from the same phone number. This is useful if you need to establish a 1:1 relationship between users and phone numbers, such as if the Salesforce user sending the message distributes business cards with a contact phone number.

When you enable the personal phone number feature, Salesforce will begin importing messages from all phone numbers in your Twilio Project. If you have some phone numbers with a high amount of traffic that are not used by Salesforce, these messages will be imported into Salesforce. Consider creating a separate Twilio Project for Twilio for Salesforce if you anticipate this issue.

Setting Up Personal Phone Numbers

Step 1: Go to the "Twilio Configuration" page and click "Enable Personal Phone Numbers".

Enable Personal Phone Numbers in Twilio for Salesforce

Step 2: Make sure you understand the warning about pulling all messages from your Twilio project and then click continue.

Reusing phone numbers for Salesforce will import messages from Twilio

Step 3: Click on "Add New"

Add Personal Phone Numbers in Twilio for Salesforce

Step 4: Select a Salesforce user from the dropdown, select the corresponding phone number, then click "Save".

Note: Users will not appear in the dropdown menu unless they have been added to the "Twilio User" permission set.

Assign a Personal Phone Number in Twilio for Salesforce

Bulk Assign Personal Phone Numbers with Data Loader

In addition to configuring personal numbers through the configuration UI, it is possible to bulk-update user phone numbers with Data Loader.

Step 1: Log in to your Salesforce organization with Data Loader.

Screen Shot 2019-04-22 at 2.10.41 PM.png

Step 2: Select the User object to extract from your Salesforce organization and pick the directory where this data will be extracted to.

Screen Shot 2019-04-22 at 2.11.15 PM.png

Step 3: Choose the fields to extract from the user:

  • User ID (Required)
  • First Name (Optional)
  • Last Name (Optional)

User ID and TWILIO_PERSONAL_NUMBER__C are the only required columns, but you should include others to make spot-checking easier.

Screen Shot 2019-04-22 at 2.22.03 PM.png

Step 4: Click on "Finish" to extract the User records to your computer.

Step 5: In Microsoft Excel, Google Sheets, or another spreadsheet editor, match User IDs to a list of Personal Phone Numbers (note: these numbers must be in your Twilio Account).

Note: All phone numbers must be in the E.164 formt (e.g. +1234567890). Do not include parentheses, spaces or dashes and prepend a + sign. If you're using excel, make sure that the cell type is text so that it doesn't strip out the +.

Screen Shot 2019-04-22 at 2.14.47 PM.png

Step 6: In Data Loader, click on "Update", select "User" as the object to update, and the select the CSV file with your personal numbers assignments.

Screen Shot 2019-04-22 at 2.29.16 PM.png

Screen Shot 2019-04-22 at 2.30.49 PM.png

Step 7: Map the User ID field to the User ID field in data loader, and map the phone number column to TWILIO_PERSONAL_NUMBER__C.

Screen Shot 2019-04-22 at 2.33.41 PM.png

Step 8: Set your log folder so that you can view debug logs if necessary. This is typically the same folder as your data source.

Step 9: Click Finish in the wizard and import your data.

After you have configured your phone numbers, you should see the appear in the UI in the Twilio Configuration page.

Screen Shot 2019-04-22 at 2.43.35 PM.png

As Twilio for Salesforce bulk assigns personal numbers, we check to make sure that each phone number is present in your Twilio Account. If a number is invalid, we set the TWILIO_PERSONAL_NUMBER_IS_VALID__C on the User record to false. This will allow you to check and update phone numbers that were entered incorrectly or do not exist in your Twilio account.

Rate this page:

Need some help?

We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the Twilio tag on Stack Overflow.


        Thank you for your feedback!

        We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

        Sending your feedback...
        🎉 Thank you for your feedback!
        Something went wrong. Please try again.

        Thanks for your feedback!

        Refer us and get $10 in 3 simple steps!

        Step 1

        Get link

        Get a free personal referral link here

        Step 2

        Give $10

        Your user signs up and upgrade using link

        Step 3

        Get $10

        1,250 free SMSes
        OR 1,000 free voice mins
        OR 12,000 chats
        OR more