- [new]
client.sendComment(objectId, comment)
- support attachment as comment:
await client.sendComment('<object_id>', 'ok!'); // send as text message
await client.sendComment('<object_id>', { message: 'ok!' });
await client.sendComment('<object_id>', { attachment_id: '<attachment_id>' });
await client.sendComment('<object_id>', {
attachment_share_url: 'https://example.com/img.gif',
});
await client.sendComment('<object_id>', {
attachment_url: 'https://example.com/img.jpg',
});
- [new]
context.sendComment(comment)
- support attachment as comment:
await context.sendComment('ok!'); // send as text message
await context.sendComment({ message: 'ok!' });
await context.sendComment({ attachment_id: '<attachment_id>' });
await context.sendComment({
attachment_share_url: 'https://example.com/img.gif',
});
await context.sendComment({ attachment_url: 'https://example.com/img.jpg' });