I pass a notion database id via a webhook.
I then connect to corresponding Notion database.
After this, i’d like to Search Objects so that I can retrieve only some Pages with a specific filter on a property (eg “Name”=“Peter”).
-
with already made Notion module ‘Search objects’:
Search Database Items, I put my webhook variable notion_db_id in the Database ID field.
But then I cannot use any filter! Nothing appears, and I cannot seem to connect it to the correct properties.values. -
making a direct API call
via a POST request to query a database https://developers.notion.com/reference/post-database-query
I’m struggling to obtain the correct query string.
I thought passing (in the Query field, not mapped) something like
'{
"filter": {
"property": "Name",
"select": {
"equals": "Peter"
}
}
}'
…would work, but i get the following error
Array of objects expected in parameter ‘qs’.
SO, clearly the format of the data i’m passing in the query string is not correct, and I don’t understand why.
it seems to be a correct JSON structure ?
Can somebody give me some idea so that I can filter the pages of the database with an Database ID passed as a variable and not hardcoded?
Thank you