<aside> đ
Links (Object base class)
Notion Ruby Mapping Public API Reference
</aside>
<aside> âšī¸
â Table of Contents
</aside>
CommentObject.find(comment_id) creates a CommentObject with retrieving comment API. The created object has comment information generated from the JSON response.
co = CommentObject.find "37921658-0840-45ae-924a-d9ce1d60375b"
# => #<NotionRubyMapping::CommentObject:...>
co.full_text
# => "comment for edit text"
full_text returns the concatenated plain text of rich text objects.
co = CommentObject.new text_objects: "ABC"
# => #<NotionRubyMapping::CommentObject:...
co.full_text
# => "ABC"
rich_text_objects= updates comment by rich text.
co = CommentObject.find "37921658-0840-45ae-924a-d9ce1d60375b"
co.rich_text_objects = "update comment by rich text"
co.save
co.full_text
# => "update comment by rich text"
markdown= updates comment by markdown.
co = CommentObject.find "37921658-0840-45ae-924a-d9ce1d60375b"
co.markdown = "update comment by markdown"
co.save
co.full_text
# => "update comment by markdown"