I have the database id but I want to access a block containing a pdf. The block is there in the page and the page is present in the database. So is there a way to access the block id from the database id?
Asked
Active
Viewed 829 times
1 Answers
2
Query the database first to get the page_id, then use the get block children endpoint to get the blocks of that page. You can then extract the PDF block

Jonas Scholz
- 485
- 5
- 15
-
How will I get the blocks of that page using get block children as this itself requires block id? – imk Dec 03 '21 at 04:33
-
2The page id is the block id! – Jonas Scholz Dec 03 '21 at 10:26
-
Please accept the answer if it solved your problem! – Jonas Scholz Dec 05 '21 at 10:02