Twilio Conversations Quickstart - Twilio

PHOTO EMBED

Wed May 05 2021 15:54:44 GMT+0000 (UTC)

Saved by @faheem

# Download the helper library from https://www.twilio.com/docs/python/install
import os
from twilio.rest import Client


# Your Account Sid and Auth Token from twilio.com/console
# and set the environment variables. See http://twil.io/secure
account_sid = os.environ['TWILIO_ACCOUNT_SID']
auth_token = os.environ['TWILIO_AUTH_TOKEN']
client = Client(account_sid, auth_token)

conversation = client.conversations \
                     .conversations \
                     .create(friendly_name='My First Conversation')

print(conversation.sid)
content_copyCOPY

https://www.twilio.com/docs/conversations/quickstart