facebookresearch / Ad-Library-API-Script-Repository

GitHub repository of commonly used python scripts that allows everyone to pull data via the Ad Library API
Other
213 stars 84 forks source link

How to find page ids from URL? #25

Closed NickCrews closed 1 year ago

NickCrews commented 1 year ago

I'm trying to look at the ads run by specific pages (~200 of them). I have these in the form of URLs of pages.

I have this working once I have the page id, but I can't figure out an automated way of finding the page id from a URL.

Any tips?

Thank you!

hcych1 commented 1 year ago

Hi Nick, unfortunately, the Ad Library API does not have the capability to convert page URL's to page ID's

NickCrews commented 1 year ago

I ended up writing my own scraper as a workaround: https://gist.github.com/NickCrews/207888d33020b8fada4908f8be8dd930