top <- create_topic("new_topic")
# email subscription
subscribe(top, "example@example.com", protocol = "email")
# sms subscription
subscribe(top, "555-123-4567", protocol = "sms")
delete_topic(top)
Run the code above in your browser using DataLab