messages.resend()
Send an existing message one more time to the same conversation.
Definition
client.messages.resend(id: string|Message):Promise<Message,Error>
Parameters
Parameter | Type | Description |
---|---|---|
id | string |Message | Message ID or message object that you want to re-send |
Returns
An error will be thrown if any of the arguments are invalid.
Otherwise, once the returned Promise
is resolved, it will return the new message.
Example
const message = await client.messages.resend('some_message_id');console.log('new message', message.body);