HomeAboutMeBlogGuest
© 2025 Sejin Cha. All rights reserved.
Built with Next.js, deployed on Vercel
📌
hkob's Notion
/
NotionRubyMapping idea note
NotionRubyMapping idea note
/
Notion Ruby Mapping Public API Reference
Notion Ruby Mapping Public API Reference
/
🧮
FilesProperty
🧮

FilesProperty

👉
Links (Property base class)
🧮
CheckboxProperty
🧮
DateProperty
🧮
FormulaProperty
🧮
MultiSelectProperty
🧮
PhoneNumberProperty
🧮
RollupProperty
🧮
TitleProperty
🧮
CreatedByProperty
🧮
EmailProperty
🧮
LastEditedByProperty
🧮
NumberProperty
🧮
RelationProperty
🧮
SelectProperty
🧮
UrlProperty
🧮
CreatedTimeProperty
🧮
FilesProperty
🧮
LastEditedTimeProperty
🧮
PeopleProperty
🧮
RichTextProperty
🧮
StatusProperty
 
Notion Ruby Mapping Public API Reference
Notion Ruby Mapping Public API Reference
💡
[P] means methods for Page Property, [D] means methods for Database Property.

1. Instance methods

files → String, Hash

  1. files of Page property returns the Array of FileObject.
  1. files of Database property returns an empty Hash {}.

[P] files=(value or values)

  • [PARAM] value new email address value
  1. file=(value or values) of Page property sets the url values or FileUploadObject objects and set will_update_flag to true. It can accept not only a single URL string or FileUploadObject, but also an array containing them.
  1. file=(value or values) of Database property raises StandardError.

filter_is_empty →
🎛️
Query

filter_is_empty creates a Query object for is_empty filter.

filter_is_not_empty →
🎛️
Query

filter_is_not_empty creates a Query object for is_not_empty filter.
page.properties["File&MediaTitle"].files => [<NotionRubyMapping::FileObject:...>] db.properties["File&MediaTitle"].files => {}
page.properties["File&MediaTitle"].files = "image url" => "image url" page.properties["File&MediaTitle"].files [#<NotionRubyMapping::FileObject:XXXXXXXXXXXXXXXXX @type="external", @url="image url", @will_update=false>] fuo = FileUploadObject fname: "test.png" page.properties["File&MediaTitle"].files = ["image url", fuo] => ["image url", fuo] page.properties["File&MediaTitle"].files [#<NotionRubyMapping::FileObject:YYYYYYYYYYYYY @type="external", @url="image url", @will_update=false>, #<NotionRubyMapping::FileObject:ZZZZZZZZZZZZZ @type="file_upload_object", @file_upload_object=#<NotionRubyMapping;:FileUploadObject:AAAAAAAAAAAAAAAA, @will_update=false>] db.properties["MailTitle"].email = "hkob@example.com" # ...:in `assert_page_property': email= can execute only Page property. (StandardError)
db.properties["CreatedByTitle"].filter_is_empty => #<NotionRubyMapping::Query:0x0000000106af9ef0 @filter={"property"=>"CreatedByTitle", "created_by"=>{"is_empty"=>true}}, @page_size=100, @sort=[], @start_cursor=nil>
db.properties["CreatedByTitle"].filter_is_not_empty => #<NotionRubyMapping::Query:0x00000001104b7290 @filter={"property"=>"CreatedByTitle", "created_by"=>{"is_not_empty"=>true}}, @page_size=100, @sort=[], @start_cursor=nil>