Interaction System Overview
Understanding Pixashot's page interaction capabilities for capturing dynamic web content.
Pixashot provides a powerful interaction system that allows you to manipulate web pages before capturing screenshots. This enables accurate capture of dynamic content, handling of popups, and complex multi-step interactions.
Core Concepts
The interaction system is built on three key principles:
- Sequential Execution: Actions are performed in order, with proper waiting between steps
- Error Recovery: Robust error handling with retry capabilities
- Resource Efficiency: Smart timeouts and resource management
Basic Usage
Here's a simple example of using interactions:
{
"url": "https://example.com",
"format": "png",
"interactions": [
{
"action": "click",
"selector": "#accept-cookies"
},
{
"action": "wait_for",
"wait_for": {
"type": "network_idle",
"value": 2000
}
}
]
}
Available Actions
- Click: Click on elements
- Type: Enter text into form fields
- Hover: Hover over elements
- Scroll: Scroll to specific positions
- Wait: Various wait strategies
Error Handling
The interaction system includes built-in error handling:
- Automatic retries for failed actions
- Timeout management
- Detailed error reporting
Integration
Interactions can be combined with other Pixashot features:
- Dark mode simulation
- Custom JavaScript execution
- Viewport configuration
- Network control
Next Steps
- Learn about Wait Strategies
- Explore User Actions
- Understand Dynamic Content
Get the Latest Updates