Commit d24c66f
committed
feat(types): Add quote message property to message types
There are two types of message that can quote a past message: text and
sticker. This commit adds the `quotedMessageId` property to the
TextMessage and StickerMessage types.
It also adds the `quoteToken` property to the QuotableMessage type which
is implemented by the TextEventMessage, StickerEventMessage,
ImageEventMessage, and VideoEventMessage types.
Following partial responses are the examples of the quote message I have
received from LINE.
TextEventMessage
message: {
type: 'text',
id: '739816233962536',
quoteToken: 'SiLB-hQpo03eYKs8QIUZXIdkXd5jQ18WpElOf1F9Vgy0h403Cj-5o6nVoogKbwMrNz9z29TJEo6882_oXlMeAFtj3xGvl_JTH5sXzaVJJhDwUY6MBpNZivMkfzvqSRUkEz2DHA7D0cEw',
text: 'test'
}
StickerEventMessage
message: {
type: 'sticker',
id: '739858565045032',
quoteToken: 'Tob7KynRFeGiGl5ekRqTXW0brLv5lG9RJBCatcYUk6oUVGJEEJoseFuayl0Dli2UxYwD7Rf2NlhEVmaPlWYcCMmogeXBIb-K3oC392WY7Gy1ZFQLVNhSjRR_uuqSOd5_aua5Zu33Jq2w',
stickerId: '8768850',
packageId: '781128',
stickerResourceType: 'STATIC',
keywords: [ 'Surprised', '!!' ]
}
ImageEventMessage
message: {
type: 'image',
id: '739846531591299',
quoteToken: 'iSxGqzgbGvHXpPaBaJC86_xsZJOWID-UXSz2d1kTINipV30OYIKRxYLshDS6T6uretaPWpdM2tde04yHRB89jiKxJpxDl_Ux9lF6bzOumalBs4JC7-mjT2V-wJzWod_03dk7iS9qrO1A',
contentProvider: { type: 'line' }
}
VideoEventMessage
message: {
type: 'video',
id: '739859176903919',
quoteToken: 'OowxxHrmCNg2scypnPnfo5SA4wGY4VkQbQbXd2PseyJmd_hIoEPQG-pJyCKo17HcP3rrCxierp03h0hWkrZgcuxjcoKD5O44cuI9d28AecRnEuBq88jAwWFBJdhBXbEjp77p21hT5Anw',
duration: 2168,
contentProvider: { type: 'line' }
}
News:
https://developers.line.biz/en/news/2023/09/14/send-and-receive-quote-messages-using-the-messaging-api/
Resolve #4611 parent 77eecf0 commit d24c66f
2 files changed
+72
-43
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
429 | 429 | | |
430 | 430 | | |
431 | 431 | | |
432 | | - | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
433 | 438 | | |
434 | 439 | | |
435 | 440 | | |
| |||
486 | 491 | | |
487 | 492 | | |
488 | 493 | | |
489 | | - | |
| 494 | + | |
| 495 | + | |
490 | 496 | | |
491 | 497 | | |
492 | 498 | | |
| |||
495 | 501 | | |
496 | 502 | | |
497 | 503 | | |
498 | | - | |
| 504 | + | |
| 505 | + | |
499 | 506 | | |
500 | 507 | | |
501 | 508 | | |
| |||
552 | 559 | | |
553 | 560 | | |
554 | 561 | | |
555 | | - | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
556 | 568 | | |
557 | 569 | | |
558 | 570 | | |
| |||
632 | 644 | | |
633 | 645 | | |
634 | 646 | | |
635 | | - | |
636 | | - | |
637 | | - | |
638 | | - | |
639 | | - | |
| 647 | + | |
640 | 648 | | |
641 | | - | |
642 | | - | |
643 | | - | |
644 | | - | |
645 | | - | |
646 | | - | |
647 | | - | |
648 | | - | |
| 649 | + | |
649 | 650 | | |
650 | | - | |
| 651 | + | |
| 652 | + | |
651 | 653 | | |
| 654 | + | |
652 | 655 | | |
653 | | - | |
654 | | - | |
655 | | - | |
| 656 | + | |
656 | 657 | | |
657 | | - | |
658 | | - | |
659 | | - | |
660 | | - | |
661 | | - | |
| 658 | + | |
662 | 659 | | |
663 | 660 | | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
| 688 | + | |
| 689 | + | |
| 690 | + | |
664 | 691 | | |
665 | 692 | | |
666 | 693 | | |
| |||
753 | 780 | | |
754 | 781 | | |
755 | 782 | | |
756 | | - | |
757 | | - | |
758 | | - | |
759 | | - | |
760 | | - | |
761 | | - | |
762 | | - | |
763 | | - | |
764 | | - | |
765 | | - | |
766 | | - | |
767 | | - | |
768 | | - | |
769 | | - | |
770 | | - | |
771 | | - | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
| 787 | + | |
| 788 | + | |
| 789 | + | |
| 790 | + | |
| 791 | + | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
772 | 800 | | |
773 | 801 | | |
774 | 802 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
22 | 23 | | |
23 | 24 | | |
24 | 25 | | |
| |||
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
38 | | - | |
| 39 | + | |
39 | 40 | | |
40 | 41 | | |
41 | 42 | | |
| |||
0 commit comments