Back to Airbyte

source-notion: Unique Behaviors

airbyte-integrations/connectors/source-notion/BEHAVIOR.md

2.0.01.0 KB
Original Source

source-notion: Unique Behaviors

1. Recursive Block Retrieval Up to 30 Levels Deep

The BlocksRetriever performs depth-first recursive fetching of Notion blocks. When a block has has_children: true, the retriever immediately makes a new API call to fetch that block's children before continuing to the next sibling. This recursion continues up to a maximum depth of 30 levels.

A single page with deeply nested content (e.g., toggles inside toggles inside columns) can trigger dozens of additional API calls as the retriever walks the entire block tree. Each level of nesting adds another round of paginated API requests for that block's children.

Why this matters: What looks like a single blocks stream read can fan out into a large number of API calls proportional to the depth and breadth of the block hierarchy. A page with 5 levels of nested blocks and 10 children per level could trigger hundreds of requests from a single parent page slice. The 30-level depth limit exists to prevent infinite recursion but is otherwise not enforced by Notion's API.