I’ve got a scenario set up where I would like to sync updated tasks from Todoist in Notion.
How I want to go about this is, after an update event in Todoist, search for a specific database item in Notion to get its page ID, and the final step is to update this database item in Notion. Sounds like 3 simple steps. However, I keep having errors with the second step.
I’m using the Notion Search Objects module to search for a value in a column called “externalTaskId.” I’m using the syntax like in the screenshot.
But I’m getting this error below. How can I solve this? Additionally, is there a way to use a good debugging tool, because these errors aren’t helpful?
The operation failed with an error. [400] body failed validation. Fix one: body.filter.or[0].title should be defined, instead was undefined. body.filter.or[0].rich_text should be defined, instead was undefined. body.filter.or[0].number should be defined, instead was undefined. body.filter.or[0].checkbox should be defined, instead was undefined. body.filter.or[0].select should be defined, instead was undefined. body.filter.or[0].multi_select should be defined, instead was undefined. body.filter.or[0].status should be defined, instead was undefined. body.filter.or[0].date should be defined, instead was undefined. body.filter.or[0].people should be defined, instead was undefined. body.filter.or[0].files should be defined, instead was undefined. body.filter.or[0].url should be defined, instead was undefined. body.filter.or[0].email should be defined, instead was undefined. body.filter.or[0].phone_number should be defined, instead was undefined. body.filter.or[0].relation should be defined, instead was undefined. body.filter.or[0].created_by should be defined, instead was undefined. body.filter.or[0].created_time should be defined, instead was undefined. body.filter.or[0].last_edited_by should be defined, instead was undefined. body.filter.or[0].last_edited_time should be defined, instead was undefined. body.filter.or[0].formula should be defined, instead was undefined. body.filter.or[0].unique_id should be defined, instead was undefined. body.filter.or[0].rollup should be defined, instead was undefined. body.filter.or[0].or should be defined, instead was undefined. body.filter.or[0].and should be defined, instead was undefined.
As a first step to troubleshoot, what property type is “externalTaskId” in your Notion database? Is it a number, text, or something else?
a) If it is a number, the filter data type you select seems correct, so you can try to enclose “818739393” in the function “parseNumber()”
b) If it is a text property, then you may change the filter data type to “text: equals”
As for the error message, that is actually what the Notion API outputs, and I see your point about its lack of clarity.
An additional more detailed tool to troubleshoot is the Integromat DevTool browser extension
It is a text, so I previously selected “text equals”. But after encountering many errors, I tried changing the datatype of my Notion database to number and selected “number equals” in Make. Thanks for the ParseNumber function, but it still doesn’t work. Here is my scenario flow. Is there anything I should change here?
When you insert the database ID manually in a Search Objects module, you should see a dropdown menu of available properties to use for filtering in the database (see screenshot as an example). In your previous screenshot, it looks like you have typed the property name manually, which may be the reason why it’s not working.
So, you could try: (1) double-checking that the Connection has access to the database you want to use; (2) using the “Search” option next to “Database ID” to search for the desired database by its name; (3) re-pasting the database ID without any extra spaces at the end/beginning.
Let’s see if any of these things help, otherwise we can continue troubleshooting.
Try using the “Search” menu and typing the database name you want to use there. The ID will be automatically populated if the connection has access to it. If not, it means the connection doesn’t have access to it.
"To add databases from your Notion account to Make app:
Log in to your Notion account.
Enter into the database you want to add to Make , click on … in the top right corner, click Add connections, search for and click on the integration you previously created, and click Confirm."