Threads And Channels
Write & Update Messages
In order to write messages, you have to write to a thread about a specific resource. If the resource has a third party associated with it, the message will automatically be published to a channel.
if a third party receives a message, they are able to respond by replying to the email or sms. The response will be added to the thread and channel.
Create a messagePOST `/v1/threads/:thread`
You don't need to create the thread since it uses a predicable URL schema. Take whatever resource you want to discuss on the thread and prefix thrd_
to get the ID of the thread. If the thread did not previously exist, it will automatically be created.
Update a message
When updating or editing messages you can either include the message ID in the URL, or just keep the endpoint as /v1/threads/:thread
and include a message_id
parameter in the request body.
You can update a message by posting to the message ID.
Delete a message
You can only delete a message if you are the publisher of the message.
DELETE `/v1/threads/:thread/messages/:message`Add a reactionPOST `/v1/threads/:thread/messages/:message`
You can update a message by posting to the message ID.
Remove a reactionPOST `/v1/threads/:thread/messages/:message`
Removing a reaction is the same process as adding one but you explicitly set the reaction to a null
value.