Quick Start
.env
When to Use
Best for:- Data extraction at scale (100s-1000s of items)
- Repetitive interactions where functions can be reused
- Tasks requiring data processing and file operations
- Deterministic workflows you want to rerun
- Best performance for data collection tasks
- Slightly slower for one-off interactions vs standard Agent
- Generates Python code that can be rerun deterministically
- Perfect for refining extraction logic
extract_products
Available Libraries
The agent can use common Python libraries:- Data processing:
pandas,numpy - Web:
requests,BeautifulSoup - File formats:
csv,json,openpyxl(Excel) - Visualization:
matplotlib - Utilities:
tabulate,datetime,re - and all which you install …
Available Tools
The agent has access to browser control functions:navigate(url)- Navigate to a URLclick(index)- Click an element by indexclick_xy(x, y, button='left', click_count=1)- Click a no-index canvas, PDF, embed, or native-rendered targethover_xy(x, y)- Move over a no-index canvas, PDF, embed, or native-rendered targetinput(index, text)- Type text into an inputscroll(down, pages)- Scroll the pagescroll_xy(x, y, delta_x=0, delta_y=0)- Wheel-scroll a no-index surfaceupload_file(path)- Upload a fileevaluate(code, variables={})- Execute JavaScript and return resultsdone(text, success, files_to_display=[])- Mark task complete
*_xy coordinates are CSS viewport pixels, not screenshot pixels. If a screenshot uses a devicePixelRatio other than 1, divide its coordinates by window.devicePixelRatio first.
Exporting Sessions
CodeAgent automatically saves all executed code and JavaScript blocks during your session. You can export your complete automation workflow for sharing, version control, or re-running later.Quick Export
Export Formats
- Jupyter Notebook (.ipynb): Interactive development, sharing, documentation
- Python Script (.py): Production deployment, version control, automation
- Setup code with browser initialization
- JavaScript code blocks as Python variables
- All executed Python cells with outputs
- Ready-to-run automation workflows