Constructor and Description |
---|
MessageCreator(String pathServiceSid,
String pathChannelSid)
Construct a new MessageCreator.
|
Modifier and Type | Method and Description |
---|---|
Message |
create(TwilioRestClient client)
Make the request to the Twilio API to perform the create.
|
MessageCreator |
setAttributes(String attributes)
A valid JSON string that contains application-specific data..
|
MessageCreator |
setBody(String body)
The message to send to the channel.
|
MessageCreator |
setDateCreated(org.joda.time.DateTime dateCreated)
The date, specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
format, to assign to the resource as the date it was created.
|
MessageCreator |
setDateUpdated(org.joda.time.DateTime dateUpdated)
The date, specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
format, to assign to the resource as the date it was last updated..
|
MessageCreator |
setFrom(String from)
The [Identity](https://www.twilio.com/docs/chat/identity) of the new
message's author.
|
MessageCreator |
setLastUpdatedBy(String lastUpdatedBy)
The [Identity](https://www.twilio.com/docs/chat/identity) of the User who
last updated the Message, if applicable..
|
MessageCreator |
setMediaSid(String mediaSid)
The SID of the [Media](https://www.twilio.com/docs/chat/rest/media) to attach
to the new Message..
|
MessageCreator |
setXTwilioWebhookEnabled(Message.WebhookEnabledType xTwilioWebhookEnabled)
The X-Twilio-Webhook-Enabled HTTP request header.
|
create, createAsync, createAsync
public MessageCreator setFrom(String from)
from
- The Identity of the new message's authorpublic MessageCreator setAttributes(String attributes)
attributes
- A valid JSON string that contains application-specific datapublic MessageCreator setDateCreated(org.joda.time.DateTime dateCreated)
dateCreated
- The ISO 8601 date and time in GMT when the resource was
createdpublic MessageCreator setDateUpdated(org.joda.time.DateTime dateUpdated)
dateUpdated
- The ISO 8601 date and time in GMT when the resource was
updatedpublic MessageCreator setLastUpdatedBy(String lastUpdatedBy)
lastUpdatedBy
- The Identity of the User who last updated the Messagepublic MessageCreator setBody(String body)
body
- The message to send to the channelpublic MessageCreator setMediaSid(String mediaSid)
mediaSid
- The Media Sid to be attached to the new Messagepublic MessageCreator setXTwilioWebhookEnabled(Message.WebhookEnabledType xTwilioWebhookEnabled)
xTwilioWebhookEnabled
- The X-Twilio-Webhook-Enabled HTTP request headerpublic Message create(TwilioRestClient client)
Copyright © 2019 Twilio, Inc. All Rights Reserved.