Interact / Browser Sandbox Endpoints
Interact with a Scraped Page
Execute code or an AI prompt in the browser session bound to a scrape job.
POST
Interact with the browser session associated with a scrape job
Use this endpoint to continue interacting with the same browser state initialized from a previous scrape. Either
code or prompt must be provided — not both.
POST /v2/scrape/{jobId}/interact handles the full lifecycle:
- If no browser session exists for this scrape job yet, Firecrawl creates one at the same page state as the original scrape, browsing from the scrape’s
location.country(the US if the scrape set none). - When
codeis provided, Firecrawl runs it in the browser sandbox. Whenpromptis provided, an AI agent automates the task using natural language. - Later
POST /interactcalls on the samejobIdreuse the same live browser state.
DELETE /v2/scrape/{jobId}/interact to stop the session.
Path Parameters
Request Body
Response
Example Request (Code)
Example Response (Code)
Example Request (Prompt)
Example Response (Prompt)
Error Codes
For detailed usage with examples, see the Interact feature guide.
Authorizations
Body
application/json
Response
Code executed successfully

