file-download Scenario 4 — Select Export Format and Download
Written by RTILA X Engineering Team
Advanced ~10 min
Prerequisites: file-download/1
What You'll Learn
Save a web page as PDF
Real-World Use Case
Generating printable reports
LIVE DEMO
Export Format Selection
Pick an export format and trigger the download.
| Metric | Value |
|---|---|
| Visitors | 12,480 |
| Conversions | 846 |
| Revenue | $84,210 |
| Avg. Session | 4m 12s |
| Bounce Rate | 42.5% |
EXPECTED OUTPUT
Export Status
{
"message": "Exporting as JSON... Download started."
}
RTILA X PROJECT JSON
RTILA X Automation Project
select-export-and-download.json
{
"name": "Select_Export_And_Download",
"settings": {
"urls": [
"https://learn.rtila.com/scenarios/file-download/4"
]
},
"datasets": {
"export_status": {
"item_selector": "css=#export-status",
"properties": [
{
"name": "message",
"type": "text",
"selector": "css=self"
}
]
}
},
"commands": [
{
"command": "select_option",
"params": {
"selector": "css=#export-format",
"value": "JSON"
}
},
{
"command": "wait_for_selector",
"params": {
"selector": "css=#export-btn"
}
},
{
"command": "click",
"params": {
"selector": "css=#export-btn"
}
},
{
"command": "wait_for_selector",
"params": {
"selector": "css=#export-status"
}
},
{
"command": "extract_data",
"params": {
"dataset": "export_status"
}
}
]
} RTILA X Concepts
The select_option command sets the export format before triggering the download. After clicking Export, the status message is extracted.
Did you complete this scenario?
Ready to run this automation?
Copy the project JSON above, open RTILA X, create a new project, and paste it.
This scenario covers 1 RTILA X command and is referenced in 1 learning article.
Continue Learning
Was this helpful?
Thank you for your feedback!