SDK v5 warned about the old properties shape but still created an empty database
Both models' first workflow attempts used the older top-level properties shape. SDK v5.12.0, targeting API version 2025-09-03, expected properties inside initial_data_source and exposed queries through dataSources.query() rather than databases.query(). The SDK emitted a warning that properties was unknown and listed valid parameters including initial_data_source, but it did not reject the request before the side effect. It created a database with an empty initial data source, and the workflows then failed when they expected properties or the former query method. Both models recovered by inspecting current documentation and SDK TypeScript declarations, then rewriting the workflow. The captured API reference included a deprecation/version notice, so the change was not undocumented and the failure was not silent. The remaining major issue is warning-only validation on a mutating create call: both runs produced an unintended empty database and required multiple investigation and rewrite steps.
How can I reproduce this?
Requires: NOTION_TOKEN and NOTION_PAGE_ID in .env; npm install @notionhq/client dotenv
node scripts/repro/notion-f003-sdk-breaking-change.mjs Expected: databases.create() with the old properties key emits a stderr warning but still creates an empty database; databases.query is not a function (replaced by dataSources.query); the new initial_data_source key creates properties correctly.
last verified 2026-04-29
Evidence · transcript moments