from firecrawl import FirecrawlApp
# Initialize the app
app = FirecrawlApp(api_key = "fc-XXXXX")
# URL to scrape
url = 'https://www.kickstarter.com/discover/advanced?category_id=35&sort=popularity&page=1'
# Define the actions to be performed
actions = [
{"type": "wait", "selector": ".load_more"},
{"type": "scroll", "direction": "down", "amount": 2000 },
{"type": "click", "selector": ".load_more"},
{"type": "scroll", "direction": "down", "amount": 2000 },
{"type": "screenshot", "fullPage": True},
{"type": "scrape"}
]
# Perform actions and scrape
result = app.scrape_url(url,
params={
'formats': ['html', 'screenshot'],
'actions': actions,
'timeout': 999999
})
# show screenshot
print(result['screenshot'])
from firecrawl import FirecrawlApp
# Initialize the app
app = FirecrawlApp(api_key = "fc-XXXXX")
# URL to scrape
url = 'https://www.kickstarter.com/discover/advanced?category_id=35&sort=popularity&page=1'
# Define the actions to be performed
actions = [
{"type": "wait", "selector": ".load_more"},
{"type": "scroll", "direction": "down", "amount": 2000 },
{"type": "click", "selector": ".load_more"},
{"type": "scroll", "direction": "down", "amount": 2000 },
{"type": "screenshot", "fullPage": True},
{"type": "scrape"}
]
# Perform actions and scrape
result = app.scrape_url(url,
params={
'formats': ['html', 'screenshot'],
'actions': actions,
'timeout': 999999
})
# show screenshot
print(result['screenshot'])