<aside> 👉 Links (Property base class)
Notion Ruby Mapping Public API Reference
</aside>
<aside> 💡
[P] means methods for Page Property, [DB/DS] means methods for Database or DataSource Property.
</aside>
The methods below return a Query without sending an API request or changing the URL value. They are available on Page, Database and DataSource property objects; query examples use DataSource properties. The examples show the generated Hash through Query#filter, not search results.
For ordinary URL filters, omit condition: and another_type: (both default to nil). The shared implementation accepts them for Formula / Rollup use, but they are not needed for a URL condition. Use filter_is_empty / filter_is_not_empty for empty-value searches rather than passing nil as a string comparison value. Values are passed to the filter without URL parsing or normalization by these methods.
Creates a Query that matches URLs containing the given substring.
String; the URL or substring to compare.ds.properties["UrlTitle"].filter_contains("example.com").filter
# => {"property" => "UrlTitle", "url" => {"contains" => "example.com"}}
Creates a Query that matches URLs not containing the given substring.
String; the URL or substring to compare.ds.properties["UrlTitle"].filter_does_not_contain("example.com").filter
# => {"property" => "UrlTitle", "url" => {"does_not_contain" => "example.com"}}
Creates a Query that matches URLs not equal to the given value.
String; the URL or substring to compare.ds.properties["UrlTitle"].filter_does_not_equal("https://example.com/").filter
# => {"property" => "UrlTitle", "url" => {"does_not_equal" => "https://example.com/"}}
Creates a Query that matches URLs ending with the given suffix.