Add Example
curl --request POST \
--url https://api.example.com/api/v1/add_example \
--header 'Content-Type: application/json' \
--header 'x-api-key: <x-api-key>' \
--data '
{
"automation": {
"url": "<string>",
"parameters": {
"input_parameters": {},
"generated_parameters": {},
"secure_parameters": {}
},
"nodes": [
{
"type": "<string>",
"interaction_action": {
"max_tries": 10,
"max_timeout_seconds_per_try": 1,
"verify_before_step": true,
"click_element": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"double_click": false,
"expect_download": false,
"download_filename": "<string>",
"button": "left",
"mouse_click": false,
"mouse_click_deviation": {},
"force": false
},
"input_text": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"input_text": "<string>",
"is_slider": false,
"fill_or_type": "fill",
"press_enter": false,
"click_before_input": true
},
"select_option": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"select_values": [
"<string>"
],
"expect_download": false,
"download_filename": "<string>"
},
"check": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
},
"uncheck": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
},
"hover": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
},
"download_url_as_pdf": {
"download_filename": "<string>",
"url": "<string>"
},
"scroll": {
"down": true,
"amount": -1,
"prompt_instructions": "<string>"
},
"upload_file": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"file_path": "<string>",
"file_url": "<string>"
},
"go_to_url": {
"url": "<string>",
"new_tab": false
},
"go_back": {},
"switch_tab": {
"tab_index": 123
},
"close_current_tab": {},
"close_all_but_last_tab": {},
"close_tabs_until": {
"matching_url": "<string>",
"tab_index": 123
},
"agentic_task": {
"task": "<string>",
"max_steps": 123,
"backend": "browser_use",
"use_vision": false,
"keep_alive": true
},
"close_overlay_popup": {
"task": "\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\n\n---\n\n### 🎯 Goal\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\n\n### 📜 Scope of Target Overlays\nTarget elements include, but are not limited to, the following common types of overlays:\n* Cookie Consent Banners/Modals\n* Privacy Policy Notices\n* Email/Newsletter Sign-up Prompts\n* Age Verification Gates\n* Blocking Promotional Offers\n\n### ⚙️ Action Priority and Rules\n\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\n\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \"Accept,\" \"Agree,\" \"Got it,\" \"Allow All,\" or similar positive confirmation phrases.\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \"Close,\" \"X\" (close icon), \"No Thanks,\" \"Maybe Later,\" \"Skip,\" or \"Continue to site.\"\n3. **Avoidance:** Do **not** input text, or click buttons like \"Sign Up,\" \"Learn More,\" or links that navigate away from the current page (e.g., \"Read Full Policy\"). The goal is solely to dismiss the current obstruction.\n\n### 🛑 Completion State\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\n",
"max_steps": 5,
"backend": "browser_use",
"use_vision": true,
"keep_alive": true
},
"key_press": {
"type": "<string>",
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
}
},
"assertion_action": {
"network_call": {
"url_pattern": "<string>",
"header_filter": {}
},
"llm": {
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": [
"screenshot"
],
"extraction_format": {
"assertion_result": "bool",
"assertion_reason": "str"
},
"recording_screenshot": "<string>",
"output_variable_names": [
"<string>"
],
"include_full_page": false
},
"python_script": {
"script": "<string>"
}
},
"extraction_action": {
"unique_identifier": "<string>",
"allow_none": false,
"network_call": {
"url_pattern": "<string>",
"extract_from": "response",
"download_from": "response",
"download_filename": "<string>"
},
"llm": {
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": [
"axtree"
],
"recording_screenshot": "<string>",
"output_variable_names": [
"<string>"
],
"include_full_page": false
},
"python_script": {
"script": "<string>",
"extraction_format": {},
"output_variable_names": [
"<string>"
]
},
"screenshot": {
"filename": "<string>",
"full_page": true
},
"state": {},
"two_fa_action": {
"action": {
"type": "<string>",
"receiver_email_address": "<string>",
"sender_email_address": "<string>",
"integration_email_address": "<string>"
},
"output_variable_name": "<string>",
"instructions": "<string>",
"max_wait_time": 300,
"check_interval": 30,
"start_2fa_time_offset_minutes": 0,
"end_2fa_time_offset_minutes": 0
},
"pdf": {
"filename": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"ocr_coordinates": {
"source_variable": "<string>",
"output_x_variable": "coords_x",
"output_y_variable": "coords_y",
"bounding_box_variables": [
"<string>"
]
},
"locator": {
"command": "<string>",
"output_variable_name": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"vision": {
"prompt": "<string>",
"output_variable_names": [
"<string>"
]
},
"api_call": {
"url": "<string>",
"method": "GET",
"headers": {},
"body": {},
"query_params": {},
"output_variable_names": [
"<string>"
],
"timeout": 30,
"poll_condition": "<string>",
"poll_interval": 5,
"max_poll_attempts": 10
}
},
"python_script_action": {
"execution_code": "<string>"
},
"powershell_action": {
"commands": [
"<string>"
],
"exit_after_commands": true
},
"sleep_action": {
"sleep_time": 123
},
"fail_state_action": {
"failure_message": "Automation completed at one of the failure states."
},
"captcha_action": {
"locator": "<string>",
"secondary_locator": "<string>",
"wait_time": 2,
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-pro",
"config": {}
},
"misc_action": {
"set_variable": {
"name": "<string>",
"value": 123,
"expression": "<string>"
},
"llm_query": {
"output_format": {},
"prompt_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"output_variable_names": [
"<string>"
]
}
},
"human_in_loop_action": {
"max_wait_time": 123
},
"before_sleep_time": 0,
"end_sleep_time": 5,
"expect_new_tab": false,
"max_new_tab_wait_time": 0,
"localized_axtree_string": "<string>"
}
],
"browser_channel": "chromium",
"backend": "browser-use",
"allow_cookies": false,
"max_retries": 0,
"expected_downloads": 0,
"remove_empty_nodes_in_axtree": true,
"take_final_screenshot": true,
"automation_description": "<string>",
"automation_endpoint": "<string>",
"post_processing_nodes": []
},
"description": "<string>",
"endpoint_name": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/add_example"
payload = {
"automation": {
"url": "<string>",
"parameters": {
"input_parameters": {},
"generated_parameters": {},
"secure_parameters": {}
},
"nodes": [
{
"type": "<string>",
"interaction_action": {
"max_tries": 10,
"max_timeout_seconds_per_try": 1,
"verify_before_step": True,
"click_element": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"double_click": False,
"expect_download": False,
"download_filename": "<string>",
"button": "left",
"mouse_click": False,
"mouse_click_deviation": {},
"force": False
},
"input_text": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"input_text": "<string>",
"is_slider": False,
"fill_or_type": "fill",
"press_enter": False,
"click_before_input": True
},
"select_option": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"select_values": ["<string>"],
"expect_download": False,
"download_filename": "<string>"
},
"check": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
},
"uncheck": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
},
"hover": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
},
"download_url_as_pdf": {
"download_filename": "<string>",
"url": "<string>"
},
"scroll": {
"down": True,
"amount": -1,
"prompt_instructions": "<string>"
},
"upload_file": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"file_path": "<string>",
"file_url": "<string>"
},
"go_to_url": {
"url": "<string>",
"new_tab": False
},
"go_back": {},
"switch_tab": { "tab_index": 123 },
"close_current_tab": {},
"close_all_but_last_tab": {},
"close_tabs_until": {
"matching_url": "<string>",
"tab_index": 123
},
"agentic_task": {
"task": "<string>",
"max_steps": 123,
"backend": "browser_use",
"use_vision": False,
"keep_alive": True
},
"close_overlay_popup": {
"task": "
The primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.
---
### 🎯 Goal
Clear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.
### 📜 Scope of Target Overlays
Target elements include, but are not limited to, the following common types of overlays:
* Cookie Consent Banners/Modals
* Privacy Policy Notices
* Email/Newsletter Sign-up Prompts
* Age Verification Gates
* Blocking Promotional Offers
### ⚙️ Action Priority and Rules
The agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:
1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \"Accept,\" \"Agree,\" \"Got it,\" \"Allow All,\" or similar positive confirmation phrases.
2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \"Close,\" \"X\" (close icon), \"No Thanks,\" \"Maybe Later,\" \"Skip,\" or \"Continue to site.\"
3. **Avoidance:** Do **not** input text, or click buttons like \"Sign Up,\" \"Learn More,\" or links that navigate away from the current page (e.g., \"Read Full Policy\"). The goal is solely to dismiss the current obstruction.
### 🛑 Completion State
The task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.
",
"max_steps": 5,
"backend": "browser_use",
"use_vision": True,
"keep_alive": True
},
"key_press": {
"type": "<string>",
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
}
},
"assertion_action": {
"network_call": {
"url_pattern": "<string>",
"header_filter": {}
},
"llm": {
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": ["screenshot"],
"extraction_format": {
"assertion_result": "bool",
"assertion_reason": "str"
},
"recording_screenshot": "<string>",
"output_variable_names": ["<string>"],
"include_full_page": False
},
"python_script": { "script": "<string>" }
},
"extraction_action": {
"unique_identifier": "<string>",
"allow_none": False,
"network_call": {
"url_pattern": "<string>",
"extract_from": "response",
"download_from": "response",
"download_filename": "<string>"
},
"llm": {
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": ["axtree"],
"recording_screenshot": "<string>",
"output_variable_names": ["<string>"],
"include_full_page": False
},
"python_script": {
"script": "<string>",
"extraction_format": {},
"output_variable_names": ["<string>"]
},
"screenshot": {
"filename": "<string>",
"full_page": True
},
"state": {},
"two_fa_action": {
"action": {
"type": "<string>",
"receiver_email_address": "<string>",
"sender_email_address": "<string>",
"integration_email_address": "<string>"
},
"output_variable_name": "<string>",
"instructions": "<string>",
"max_wait_time": 300,
"check_interval": 30,
"start_2fa_time_offset_minutes": 0,
"end_2fa_time_offset_minutes": 0
},
"pdf": {
"filename": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"ocr_coordinates": {
"source_variable": "<string>",
"output_x_variable": "coords_x",
"output_y_variable": "coords_y",
"bounding_box_variables": ["<string>"]
},
"locator": {
"command": "<string>",
"output_variable_name": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"vision": {
"prompt": "<string>",
"output_variable_names": ["<string>"]
},
"api_call": {
"url": "<string>",
"method": "GET",
"headers": {},
"body": {},
"query_params": {},
"output_variable_names": ["<string>"],
"timeout": 30,
"poll_condition": "<string>",
"poll_interval": 5,
"max_poll_attempts": 10
}
},
"python_script_action": { "execution_code": "<string>" },
"powershell_action": {
"commands": ["<string>"],
"exit_after_commands": True
},
"sleep_action": { "sleep_time": 123 },
"fail_state_action": { "failure_message": "Automation completed at one of the failure states." },
"captcha_action": {
"locator": "<string>",
"secondary_locator": "<string>",
"wait_time": 2,
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-pro",
"config": {}
},
"misc_action": {
"set_variable": {
"name": "<string>",
"value": 123,
"expression": "<string>"
},
"llm_query": {
"output_format": {},
"prompt_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"output_variable_names": ["<string>"]
}
},
"human_in_loop_action": { "max_wait_time": 123 },
"before_sleep_time": 0,
"end_sleep_time": 5,
"expect_new_tab": False,
"max_new_tab_wait_time": 0,
"localized_axtree_string": "<string>"
}
],
"browser_channel": "chromium",
"backend": "browser-use",
"allow_cookies": False,
"max_retries": 0,
"expected_downloads": 0,
"remove_empty_nodes_in_axtree": True,
"take_final_screenshot": True,
"automation_description": "<string>",
"automation_endpoint": "<string>",
"post_processing_nodes": []
},
"description": "<string>",
"endpoint_name": "<string>"
}
headers = {
"x-api-key": "<x-api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<x-api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
automation: {
url: '<string>',
parameters: {input_parameters: {}, generated_parameters: {}, secure_parameters: {}},
nodes: [
{
type: '<string>',
interaction_action: {
max_tries: 10,
max_timeout_seconds_per_try: 1,
verify_before_step: true,
click_element: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
double_click: false,
expect_download: false,
download_filename: '<string>',
button: 'left',
mouse_click: false,
mouse_click_deviation: {},
force: false
},
input_text: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
input_text: '<string>',
is_slider: false,
fill_or_type: 'fill',
press_enter: false,
click_before_input: true
},
select_option: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
select_values: ['<string>'],
expect_download: false,
download_filename: '<string>'
},
check: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
},
uncheck: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
},
hover: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
},
download_url_as_pdf: {download_filename: '<string>', url: '<string>'},
scroll: {down: true, amount: -1, prompt_instructions: '<string>'},
upload_file: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
file_path: '<string>',
file_url: '<string>'
},
go_to_url: {url: '<string>', new_tab: false},
go_back: {},
switch_tab: {tab_index: 123},
close_current_tab: {},
close_all_but_last_tab: {},
close_tabs_until: {matching_url: '<string>', tab_index: 123},
agentic_task: {
task: '<string>',
max_steps: 123,
backend: 'browser_use',
use_vision: false,
keep_alive: true
},
close_overlay_popup: {
task: '\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\n\n---\n\n### 🎯 Goal\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\n\n### 📜 Scope of Target Overlays\nTarget elements include, but are not limited to, the following common types of overlays:\n* Cookie Consent Banners/Modals\n* Privacy Policy Notices\n* Email/Newsletter Sign-up Prompts\n* Age Verification Gates\n* Blocking Promotional Offers\n\n### ⚙️ Action Priority and Rules\n\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\n\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled "Accept," "Agree," "Got it," "Allow All," or similar positive confirmation phrases.\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like "Close," "X" (close icon), "No Thanks," "Maybe Later," "Skip," or "Continue to site."\n3. **Avoidance:** Do **not** input text, or click buttons like "Sign Up," "Learn More," or links that navigate away from the current page (e.g., "Read Full Policy"). The goal is solely to dismiss the current obstruction.\n\n### 🛑 Completion State\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\n',
max_steps: 5,
backend: 'browser_use',
use_vision: true,
keep_alive: true
},
key_press: {
type: '<string>',
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
}
},
assertion_action: {
network_call: {url_pattern: '<string>', header_filter: {}},
llm: {
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash',
source: ['screenshot'],
extraction_format: {assertion_result: 'bool', assertion_reason: 'str'},
recording_screenshot: '<string>',
output_variable_names: ['<string>'],
include_full_page: false
},
python_script: {script: '<string>'}
},
extraction_action: {
unique_identifier: '<string>',
allow_none: false,
network_call: {
url_pattern: '<string>',
extract_from: 'response',
download_from: 'response',
download_filename: '<string>'
},
llm: {
extraction_format: {},
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash',
source: ['axtree'],
recording_screenshot: '<string>',
output_variable_names: ['<string>'],
include_full_page: false
},
python_script: {script: '<string>', extraction_format: {}, output_variable_names: ['<string>']},
screenshot: {filename: '<string>', full_page: true},
state: {},
two_fa_action: {
action: {
type: '<string>',
receiver_email_address: '<string>',
sender_email_address: '<string>',
integration_email_address: '<string>'
},
output_variable_name: '<string>',
instructions: '<string>',
max_wait_time: 300,
check_interval: 30,
start_2fa_time_offset_minutes: 0,
end_2fa_time_offset_minutes: 0
},
pdf: {
filename: '<string>',
extraction_format: {},
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash'
},
ocr_coordinates: {
source_variable: '<string>',
output_x_variable: 'coords_x',
output_y_variable: 'coords_y',
bounding_box_variables: ['<string>']
},
locator: {
command: '<string>',
output_variable_name: '<string>',
extraction_format: {},
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash'
},
vision: {prompt: '<string>', output_variable_names: ['<string>']},
api_call: {
url: '<string>',
method: 'GET',
headers: {},
body: JSON.stringify({}),
query_params: {},
output_variable_names: ['<string>'],
timeout: 30,
poll_condition: '<string>',
poll_interval: 5,
max_poll_attempts: 10
}
},
python_script_action: {execution_code: '<string>'},
powershell_action: {commands: ['<string>'], exit_after_commands: true},
sleep_action: {sleep_time: 123},
fail_state_action: {failure_message: 'Automation completed at one of the failure states.'},
captcha_action: {
locator: '<string>',
secondary_locator: '<string>',
wait_time: 2,
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-pro',
config: {}
},
misc_action: {
set_variable: {name: '<string>', value: 123, expression: '<string>'},
llm_query: {
output_format: {},
prompt_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash',
output_variable_names: ['<string>']
}
},
human_in_loop_action: {max_wait_time: 123},
before_sleep_time: 0,
end_sleep_time: 5,
expect_new_tab: false,
max_new_tab_wait_time: 0,
localized_axtree_string: '<string>'
}
],
browser_channel: 'chromium',
backend: 'browser-use',
allow_cookies: false,
max_retries: 0,
expected_downloads: 0,
remove_empty_nodes_in_axtree: true,
take_final_screenshot: true,
automation_description: '<string>',
automation_endpoint: '<string>',
post_processing_nodes: []
},
description: '<string>',
endpoint_name: '<string>'
})
};
fetch('https://api.example.com/api/v1/add_example', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v1/add_example",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'automation' => [
'url' => '<string>',
'parameters' => [
'input_parameters' => [
],
'generated_parameters' => [
],
'secure_parameters' => [
]
],
'nodes' => [
[
'type' => '<string>',
'interaction_action' => [
'max_tries' => 10,
'max_timeout_seconds_per_try' => 1,
'verify_before_step' => true,
'click_element' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'double_click' => false,
'expect_download' => false,
'download_filename' => '<string>',
'button' => 'left',
'mouse_click' => false,
'mouse_click_deviation' => [
],
'force' => false
],
'input_text' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'input_text' => '<string>',
'is_slider' => false,
'fill_or_type' => 'fill',
'press_enter' => false,
'click_before_input' => true
],
'select_option' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'select_values' => [
'<string>'
],
'expect_download' => false,
'download_filename' => '<string>'
],
'check' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
],
'uncheck' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
],
'hover' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
],
'download_url_as_pdf' => [
'download_filename' => '<string>',
'url' => '<string>'
],
'scroll' => [
'down' => true,
'amount' => -1,
'prompt_instructions' => '<string>'
],
'upload_file' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'file_path' => '<string>',
'file_url' => '<string>'
],
'go_to_url' => [
'url' => '<string>',
'new_tab' => false
],
'go_back' => [
],
'switch_tab' => [
'tab_index' => 123
],
'close_current_tab' => [
],
'close_all_but_last_tab' => [
],
'close_tabs_until' => [
'matching_url' => '<string>',
'tab_index' => 123
],
'agentic_task' => [
'task' => '<string>',
'max_steps' => 123,
'backend' => 'browser_use',
'use_vision' => false,
'keep_alive' => true
],
'close_overlay_popup' => [
'task' => '
The primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.
---
### 🎯 Goal
Clear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.
### 📜 Scope of Target Overlays
Target elements include, but are not limited to, the following common types of overlays:
* Cookie Consent Banners/Modals
* Privacy Policy Notices
* Email/Newsletter Sign-up Prompts
* Age Verification Gates
* Blocking Promotional Offers
### ⚙️ Action Priority and Rules
The agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:
1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled "Accept," "Agree," "Got it," "Allow All," or similar positive confirmation phrases.
2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like "Close," "X" (close icon), "No Thanks," "Maybe Later," "Skip," or "Continue to site."
3. **Avoidance:** Do **not** input text, or click buttons like "Sign Up," "Learn More," or links that navigate away from the current page (e.g., "Read Full Policy"). The goal is solely to dismiss the current obstruction.
### 🛑 Completion State
The task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.
',
'max_steps' => 5,
'backend' => 'browser_use',
'use_vision' => true,
'keep_alive' => true
],
'key_press' => [
'type' => '<string>',
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
]
],
'assertion_action' => [
'network_call' => [
'url_pattern' => '<string>',
'header_filter' => [
]
],
'llm' => [
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash',
'source' => [
'screenshot'
],
'extraction_format' => [
'assertion_result' => 'bool',
'assertion_reason' => 'str'
],
'recording_screenshot' => '<string>',
'output_variable_names' => [
'<string>'
],
'include_full_page' => false
],
'python_script' => [
'script' => '<string>'
]
],
'extraction_action' => [
'unique_identifier' => '<string>',
'allow_none' => false,
'network_call' => [
'url_pattern' => '<string>',
'extract_from' => 'response',
'download_from' => 'response',
'download_filename' => '<string>'
],
'llm' => [
'extraction_format' => [
],
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash',
'source' => [
'axtree'
],
'recording_screenshot' => '<string>',
'output_variable_names' => [
'<string>'
],
'include_full_page' => false
],
'python_script' => [
'script' => '<string>',
'extraction_format' => [
],
'output_variable_names' => [
'<string>'
]
],
'screenshot' => [
'filename' => '<string>',
'full_page' => true
],
'state' => [
],
'two_fa_action' => [
'action' => [
'type' => '<string>',
'receiver_email_address' => '<string>',
'sender_email_address' => '<string>',
'integration_email_address' => '<string>'
],
'output_variable_name' => '<string>',
'instructions' => '<string>',
'max_wait_time' => 300,
'check_interval' => 30,
'start_2fa_time_offset_minutes' => 0,
'end_2fa_time_offset_minutes' => 0
],
'pdf' => [
'filename' => '<string>',
'extraction_format' => [
],
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash'
],
'ocr_coordinates' => [
'source_variable' => '<string>',
'output_x_variable' => 'coords_x',
'output_y_variable' => 'coords_y',
'bounding_box_variables' => [
'<string>'
]
],
'locator' => [
'command' => '<string>',
'output_variable_name' => '<string>',
'extraction_format' => [
],
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash'
],
'vision' => [
'prompt' => '<string>',
'output_variable_names' => [
'<string>'
]
],
'api_call' => [
'url' => '<string>',
'method' => 'GET',
'headers' => [
],
'body' => [
],
'query_params' => [
],
'output_variable_names' => [
'<string>'
],
'timeout' => 30,
'poll_condition' => '<string>',
'poll_interval' => 5,
'max_poll_attempts' => 10
]
],
'python_script_action' => [
'execution_code' => '<string>'
],
'powershell_action' => [
'commands' => [
'<string>'
],
'exit_after_commands' => true
],
'sleep_action' => [
'sleep_time' => 123
],
'fail_state_action' => [
'failure_message' => 'Automation completed at one of the failure states.'
],
'captcha_action' => [
'locator' => '<string>',
'secondary_locator' => '<string>',
'wait_time' => 2,
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-pro',
'config' => [
]
],
'misc_action' => [
'set_variable' => [
'name' => '<string>',
'value' => 123,
'expression' => '<string>'
],
'llm_query' => [
'output_format' => [
],
'prompt_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash',
'output_variable_names' => [
'<string>'
]
]
],
'human_in_loop_action' => [
'max_wait_time' => 123
],
'before_sleep_time' => 0,
'end_sleep_time' => 5,
'expect_new_tab' => false,
'max_new_tab_wait_time' => 0,
'localized_axtree_string' => '<string>'
]
],
'browser_channel' => 'chromium',
'backend' => 'browser-use',
'allow_cookies' => false,
'max_retries' => 0,
'expected_downloads' => 0,
'remove_empty_nodes_in_axtree' => true,
'take_final_screenshot' => true,
'automation_description' => '<string>',
'automation_endpoint' => '<string>',
'post_processing_nodes' => [
]
],
'description' => '<string>',
'endpoint_name' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <x-api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v1/add_example"
payload := strings.NewReader("{\n \"automation\": {\n \"url\": \"<string>\",\n \"parameters\": {\n \"input_parameters\": {},\n \"generated_parameters\": {},\n \"secure_parameters\": {}\n },\n \"nodes\": [\n {\n \"type\": \"<string>\",\n \"interaction_action\": {\n \"max_tries\": 10,\n \"max_timeout_seconds_per_try\": 1,\n \"verify_before_step\": true,\n \"click_element\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"double_click\": false,\n \"expect_download\": false,\n \"download_filename\": \"<string>\",\n \"button\": \"left\",\n \"mouse_click\": false,\n \"mouse_click_deviation\": {},\n \"force\": false\n },\n \"input_text\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"input_text\": \"<string>\",\n \"is_slider\": false,\n \"fill_or_type\": \"fill\",\n \"press_enter\": false,\n \"click_before_input\": true\n },\n \"select_option\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"select_values\": [\n \"<string>\"\n ],\n \"expect_download\": false,\n \"download_filename\": \"<string>\"\n },\n \"check\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"uncheck\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"hover\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"download_url_as_pdf\": {\n \"download_filename\": \"<string>\",\n \"url\": \"<string>\"\n },\n \"scroll\": {\n \"down\": true,\n \"amount\": -1,\n \"prompt_instructions\": \"<string>\"\n },\n \"upload_file\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"file_path\": \"<string>\",\n \"file_url\": \"<string>\"\n },\n \"go_to_url\": {\n \"url\": \"<string>\",\n \"new_tab\": false\n },\n \"go_back\": {},\n \"switch_tab\": {\n \"tab_index\": 123\n },\n \"close_current_tab\": {},\n \"close_all_but_last_tab\": {},\n \"close_tabs_until\": {\n \"matching_url\": \"<string>\",\n \"tab_index\": 123\n },\n \"agentic_task\": {\n \"task\": \"<string>\",\n \"max_steps\": 123,\n \"backend\": \"browser_use\",\n \"use_vision\": false,\n \"keep_alive\": true\n },\n \"close_overlay_popup\": {\n \"task\": \"\\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\\n\\n---\\n\\n### 🎯 Goal\\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\\n\\n### 📜 Scope of Target Overlays\\nTarget elements include, but are not limited to, the following common types of overlays:\\n* Cookie Consent Banners/Modals\\n* Privacy Policy Notices\\n* Email/Newsletter Sign-up Prompts\\n* Age Verification Gates\\n* Blocking Promotional Offers\\n\\n### ⚙️ Action Priority and Rules\\n\\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\\n\\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \\\"Accept,\\\" \\\"Agree,\\\" \\\"Got it,\\\" \\\"Allow All,\\\" or similar positive confirmation phrases.\\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \\\"Close,\\\" \\\"X\\\" (close icon), \\\"No Thanks,\\\" \\\"Maybe Later,\\\" \\\"Skip,\\\" or \\\"Continue to site.\\\"\\n3. **Avoidance:** Do **not** input text, or click buttons like \\\"Sign Up,\\\" \\\"Learn More,\\\" or links that navigate away from the current page (e.g., \\\"Read Full Policy\\\"). The goal is solely to dismiss the current obstruction.\\n\\n### 🛑 Completion State\\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\\n\",\n \"max_steps\": 5,\n \"backend\": \"browser_use\",\n \"use_vision\": true,\n \"keep_alive\": true\n },\n \"key_press\": {\n \"type\": \"<string>\",\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n }\n },\n \"assertion_action\": {\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"header_filter\": {}\n },\n \"llm\": {\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"screenshot\"\n ],\n \"extraction_format\": {\n \"assertion_result\": \"bool\",\n \"assertion_reason\": \"str\"\n },\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\"\n }\n },\n \"extraction_action\": {\n \"unique_identifier\": \"<string>\",\n \"allow_none\": false,\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"extract_from\": \"response\",\n \"download_from\": \"response\",\n \"download_filename\": \"<string>\"\n },\n \"llm\": {\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"axtree\"\n ],\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\",\n \"extraction_format\": {},\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"screenshot\": {\n \"filename\": \"<string>\",\n \"full_page\": true\n },\n \"state\": {},\n \"two_fa_action\": {\n \"action\": {\n \"type\": \"<string>\",\n \"receiver_email_address\": \"<string>\",\n \"sender_email_address\": \"<string>\",\n \"integration_email_address\": \"<string>\"\n },\n \"output_variable_name\": \"<string>\",\n \"instructions\": \"<string>\",\n \"max_wait_time\": 300,\n \"check_interval\": 30,\n \"start_2fa_time_offset_minutes\": 0,\n \"end_2fa_time_offset_minutes\": 0\n },\n \"pdf\": {\n \"filename\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"ocr_coordinates\": {\n \"source_variable\": \"<string>\",\n \"output_x_variable\": \"coords_x\",\n \"output_y_variable\": \"coords_y\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"locator\": {\n \"command\": \"<string>\",\n \"output_variable_name\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"vision\": {\n \"prompt\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"api_call\": {\n \"url\": \"<string>\",\n \"method\": \"GET\",\n \"headers\": {},\n \"body\": {},\n \"query_params\": {},\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"timeout\": 30,\n \"poll_condition\": \"<string>\",\n \"poll_interval\": 5,\n \"max_poll_attempts\": 10\n }\n },\n \"python_script_action\": {\n \"execution_code\": \"<string>\"\n },\n \"powershell_action\": {\n \"commands\": [\n \"<string>\"\n ],\n \"exit_after_commands\": true\n },\n \"sleep_action\": {\n \"sleep_time\": 123\n },\n \"fail_state_action\": {\n \"failure_message\": \"Automation completed at one of the failure states.\"\n },\n \"captcha_action\": {\n \"locator\": \"<string>\",\n \"secondary_locator\": \"<string>\",\n \"wait_time\": 2,\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-pro\",\n \"config\": {}\n },\n \"misc_action\": {\n \"set_variable\": {\n \"name\": \"<string>\",\n \"value\": 123,\n \"expression\": \"<string>\"\n },\n \"llm_query\": {\n \"output_format\": {},\n \"prompt_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n }\n },\n \"human_in_loop_action\": {\n \"max_wait_time\": 123\n },\n \"before_sleep_time\": 0,\n \"end_sleep_time\": 5,\n \"expect_new_tab\": false,\n \"max_new_tab_wait_time\": 0,\n \"localized_axtree_string\": \"<string>\"\n }\n ],\n \"browser_channel\": \"chromium\",\n \"backend\": \"browser-use\",\n \"allow_cookies\": false,\n \"max_retries\": 0,\n \"expected_downloads\": 0,\n \"remove_empty_nodes_in_axtree\": true,\n \"take_final_screenshot\": true,\n \"automation_description\": \"<string>\",\n \"automation_endpoint\": \"<string>\",\n \"post_processing_nodes\": []\n },\n \"description\": \"<string>\",\n \"endpoint_name\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<x-api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/v1/add_example")
.header("x-api-key", "<x-api-key>")
.header("Content-Type", "application/json")
.body("{\n \"automation\": {\n \"url\": \"<string>\",\n \"parameters\": {\n \"input_parameters\": {},\n \"generated_parameters\": {},\n \"secure_parameters\": {}\n },\n \"nodes\": [\n {\n \"type\": \"<string>\",\n \"interaction_action\": {\n \"max_tries\": 10,\n \"max_timeout_seconds_per_try\": 1,\n \"verify_before_step\": true,\n \"click_element\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"double_click\": false,\n \"expect_download\": false,\n \"download_filename\": \"<string>\",\n \"button\": \"left\",\n \"mouse_click\": false,\n \"mouse_click_deviation\": {},\n \"force\": false\n },\n \"input_text\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"input_text\": \"<string>\",\n \"is_slider\": false,\n \"fill_or_type\": \"fill\",\n \"press_enter\": false,\n \"click_before_input\": true\n },\n \"select_option\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"select_values\": [\n \"<string>\"\n ],\n \"expect_download\": false,\n \"download_filename\": \"<string>\"\n },\n \"check\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"uncheck\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"hover\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"download_url_as_pdf\": {\n \"download_filename\": \"<string>\",\n \"url\": \"<string>\"\n },\n \"scroll\": {\n \"down\": true,\n \"amount\": -1,\n \"prompt_instructions\": \"<string>\"\n },\n \"upload_file\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"file_path\": \"<string>\",\n \"file_url\": \"<string>\"\n },\n \"go_to_url\": {\n \"url\": \"<string>\",\n \"new_tab\": false\n },\n \"go_back\": {},\n \"switch_tab\": {\n \"tab_index\": 123\n },\n \"close_current_tab\": {},\n \"close_all_but_last_tab\": {},\n \"close_tabs_until\": {\n \"matching_url\": \"<string>\",\n \"tab_index\": 123\n },\n \"agentic_task\": {\n \"task\": \"<string>\",\n \"max_steps\": 123,\n \"backend\": \"browser_use\",\n \"use_vision\": false,\n \"keep_alive\": true\n },\n \"close_overlay_popup\": {\n \"task\": \"\\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\\n\\n---\\n\\n### 🎯 Goal\\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\\n\\n### 📜 Scope of Target Overlays\\nTarget elements include, but are not limited to, the following common types of overlays:\\n* Cookie Consent Banners/Modals\\n* Privacy Policy Notices\\n* Email/Newsletter Sign-up Prompts\\n* Age Verification Gates\\n* Blocking Promotional Offers\\n\\n### ⚙️ Action Priority and Rules\\n\\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\\n\\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \\\"Accept,\\\" \\\"Agree,\\\" \\\"Got it,\\\" \\\"Allow All,\\\" or similar positive confirmation phrases.\\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \\\"Close,\\\" \\\"X\\\" (close icon), \\\"No Thanks,\\\" \\\"Maybe Later,\\\" \\\"Skip,\\\" or \\\"Continue to site.\\\"\\n3. **Avoidance:** Do **not** input text, or click buttons like \\\"Sign Up,\\\" \\\"Learn More,\\\" or links that navigate away from the current page (e.g., \\\"Read Full Policy\\\"). The goal is solely to dismiss the current obstruction.\\n\\n### 🛑 Completion State\\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\\n\",\n \"max_steps\": 5,\n \"backend\": \"browser_use\",\n \"use_vision\": true,\n \"keep_alive\": true\n },\n \"key_press\": {\n \"type\": \"<string>\",\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n }\n },\n \"assertion_action\": {\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"header_filter\": {}\n },\n \"llm\": {\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"screenshot\"\n ],\n \"extraction_format\": {\n \"assertion_result\": \"bool\",\n \"assertion_reason\": \"str\"\n },\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\"\n }\n },\n \"extraction_action\": {\n \"unique_identifier\": \"<string>\",\n \"allow_none\": false,\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"extract_from\": \"response\",\n \"download_from\": \"response\",\n \"download_filename\": \"<string>\"\n },\n \"llm\": {\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"axtree\"\n ],\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\",\n \"extraction_format\": {},\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"screenshot\": {\n \"filename\": \"<string>\",\n \"full_page\": true\n },\n \"state\": {},\n \"two_fa_action\": {\n \"action\": {\n \"type\": \"<string>\",\n \"receiver_email_address\": \"<string>\",\n \"sender_email_address\": \"<string>\",\n \"integration_email_address\": \"<string>\"\n },\n \"output_variable_name\": \"<string>\",\n \"instructions\": \"<string>\",\n \"max_wait_time\": 300,\n \"check_interval\": 30,\n \"start_2fa_time_offset_minutes\": 0,\n \"end_2fa_time_offset_minutes\": 0\n },\n \"pdf\": {\n \"filename\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"ocr_coordinates\": {\n \"source_variable\": \"<string>\",\n \"output_x_variable\": \"coords_x\",\n \"output_y_variable\": \"coords_y\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"locator\": {\n \"command\": \"<string>\",\n \"output_variable_name\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"vision\": {\n \"prompt\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"api_call\": {\n \"url\": \"<string>\",\n \"method\": \"GET\",\n \"headers\": {},\n \"body\": {},\n \"query_params\": {},\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"timeout\": 30,\n \"poll_condition\": \"<string>\",\n \"poll_interval\": 5,\n \"max_poll_attempts\": 10\n }\n },\n \"python_script_action\": {\n \"execution_code\": \"<string>\"\n },\n \"powershell_action\": {\n \"commands\": [\n \"<string>\"\n ],\n \"exit_after_commands\": true\n },\n \"sleep_action\": {\n \"sleep_time\": 123\n },\n \"fail_state_action\": {\n \"failure_message\": \"Automation completed at one of the failure states.\"\n },\n \"captcha_action\": {\n \"locator\": \"<string>\",\n \"secondary_locator\": \"<string>\",\n \"wait_time\": 2,\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-pro\",\n \"config\": {}\n },\n \"misc_action\": {\n \"set_variable\": {\n \"name\": \"<string>\",\n \"value\": 123,\n \"expression\": \"<string>\"\n },\n \"llm_query\": {\n \"output_format\": {},\n \"prompt_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n }\n },\n \"human_in_loop_action\": {\n \"max_wait_time\": 123\n },\n \"before_sleep_time\": 0,\n \"end_sleep_time\": 5,\n \"expect_new_tab\": false,\n \"max_new_tab_wait_time\": 0,\n \"localized_axtree_string\": \"<string>\"\n }\n ],\n \"browser_channel\": \"chromium\",\n \"backend\": \"browser-use\",\n \"allow_cookies\": false,\n \"max_retries\": 0,\n \"expected_downloads\": 0,\n \"remove_empty_nodes_in_axtree\": true,\n \"take_final_screenshot\": true,\n \"automation_description\": \"<string>\",\n \"automation_endpoint\": \"<string>\",\n \"post_processing_nodes\": []\n },\n \"description\": \"<string>\",\n \"endpoint_name\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/add_example")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"automation\": {\n \"url\": \"<string>\",\n \"parameters\": {\n \"input_parameters\": {},\n \"generated_parameters\": {},\n \"secure_parameters\": {}\n },\n \"nodes\": [\n {\n \"type\": \"<string>\",\n \"interaction_action\": {\n \"max_tries\": 10,\n \"max_timeout_seconds_per_try\": 1,\n \"verify_before_step\": true,\n \"click_element\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"double_click\": false,\n \"expect_download\": false,\n \"download_filename\": \"<string>\",\n \"button\": \"left\",\n \"mouse_click\": false,\n \"mouse_click_deviation\": {},\n \"force\": false\n },\n \"input_text\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"input_text\": \"<string>\",\n \"is_slider\": false,\n \"fill_or_type\": \"fill\",\n \"press_enter\": false,\n \"click_before_input\": true\n },\n \"select_option\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"select_values\": [\n \"<string>\"\n ],\n \"expect_download\": false,\n \"download_filename\": \"<string>\"\n },\n \"check\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"uncheck\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"hover\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"download_url_as_pdf\": {\n \"download_filename\": \"<string>\",\n \"url\": \"<string>\"\n },\n \"scroll\": {\n \"down\": true,\n \"amount\": -1,\n \"prompt_instructions\": \"<string>\"\n },\n \"upload_file\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"file_path\": \"<string>\",\n \"file_url\": \"<string>\"\n },\n \"go_to_url\": {\n \"url\": \"<string>\",\n \"new_tab\": false\n },\n \"go_back\": {},\n \"switch_tab\": {\n \"tab_index\": 123\n },\n \"close_current_tab\": {},\n \"close_all_but_last_tab\": {},\n \"close_tabs_until\": {\n \"matching_url\": \"<string>\",\n \"tab_index\": 123\n },\n \"agentic_task\": {\n \"task\": \"<string>\",\n \"max_steps\": 123,\n \"backend\": \"browser_use\",\n \"use_vision\": false,\n \"keep_alive\": true\n },\n \"close_overlay_popup\": {\n \"task\": \"\\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\\n\\n---\\n\\n### 🎯 Goal\\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\\n\\n### 📜 Scope of Target Overlays\\nTarget elements include, but are not limited to, the following common types of overlays:\\n* Cookie Consent Banners/Modals\\n* Privacy Policy Notices\\n* Email/Newsletter Sign-up Prompts\\n* Age Verification Gates\\n* Blocking Promotional Offers\\n\\n### ⚙️ Action Priority and Rules\\n\\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\\n\\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \\\"Accept,\\\" \\\"Agree,\\\" \\\"Got it,\\\" \\\"Allow All,\\\" or similar positive confirmation phrases.\\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \\\"Close,\\\" \\\"X\\\" (close icon), \\\"No Thanks,\\\" \\\"Maybe Later,\\\" \\\"Skip,\\\" or \\\"Continue to site.\\\"\\n3. **Avoidance:** Do **not** input text, or click buttons like \\\"Sign Up,\\\" \\\"Learn More,\\\" or links that navigate away from the current page (e.g., \\\"Read Full Policy\\\"). The goal is solely to dismiss the current obstruction.\\n\\n### 🛑 Completion State\\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\\n\",\n \"max_steps\": 5,\n \"backend\": \"browser_use\",\n \"use_vision\": true,\n \"keep_alive\": true\n },\n \"key_press\": {\n \"type\": \"<string>\",\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n }\n },\n \"assertion_action\": {\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"header_filter\": {}\n },\n \"llm\": {\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"screenshot\"\n ],\n \"extraction_format\": {\n \"assertion_result\": \"bool\",\n \"assertion_reason\": \"str\"\n },\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\"\n }\n },\n \"extraction_action\": {\n \"unique_identifier\": \"<string>\",\n \"allow_none\": false,\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"extract_from\": \"response\",\n \"download_from\": \"response\",\n \"download_filename\": \"<string>\"\n },\n \"llm\": {\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"axtree\"\n ],\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\",\n \"extraction_format\": {},\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"screenshot\": {\n \"filename\": \"<string>\",\n \"full_page\": true\n },\n \"state\": {},\n \"two_fa_action\": {\n \"action\": {\n \"type\": \"<string>\",\n \"receiver_email_address\": \"<string>\",\n \"sender_email_address\": \"<string>\",\n \"integration_email_address\": \"<string>\"\n },\n \"output_variable_name\": \"<string>\",\n \"instructions\": \"<string>\",\n \"max_wait_time\": 300,\n \"check_interval\": 30,\n \"start_2fa_time_offset_minutes\": 0,\n \"end_2fa_time_offset_minutes\": 0\n },\n \"pdf\": {\n \"filename\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"ocr_coordinates\": {\n \"source_variable\": \"<string>\",\n \"output_x_variable\": \"coords_x\",\n \"output_y_variable\": \"coords_y\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"locator\": {\n \"command\": \"<string>\",\n \"output_variable_name\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"vision\": {\n \"prompt\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"api_call\": {\n \"url\": \"<string>\",\n \"method\": \"GET\",\n \"headers\": {},\n \"body\": {},\n \"query_params\": {},\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"timeout\": 30,\n \"poll_condition\": \"<string>\",\n \"poll_interval\": 5,\n \"max_poll_attempts\": 10\n }\n },\n \"python_script_action\": {\n \"execution_code\": \"<string>\"\n },\n \"powershell_action\": {\n \"commands\": [\n \"<string>\"\n ],\n \"exit_after_commands\": true\n },\n \"sleep_action\": {\n \"sleep_time\": 123\n },\n \"fail_state_action\": {\n \"failure_message\": \"Automation completed at one of the failure states.\"\n },\n \"captcha_action\": {\n \"locator\": \"<string>\",\n \"secondary_locator\": \"<string>\",\n \"wait_time\": 2,\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-pro\",\n \"config\": {}\n },\n \"misc_action\": {\n \"set_variable\": {\n \"name\": \"<string>\",\n \"value\": 123,\n \"expression\": \"<string>\"\n },\n \"llm_query\": {\n \"output_format\": {},\n \"prompt_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n }\n },\n \"human_in_loop_action\": {\n \"max_wait_time\": 123\n },\n \"before_sleep_time\": 0,\n \"end_sleep_time\": 5,\n \"expect_new_tab\": false,\n \"max_new_tab_wait_time\": 0,\n \"localized_axtree_string\": \"<string>\"\n }\n ],\n \"browser_channel\": \"chromium\",\n \"backend\": \"browser-use\",\n \"allow_cookies\": false,\n \"max_retries\": 0,\n \"expected_downloads\": 0,\n \"remove_empty_nodes_in_axtree\": true,\n \"take_final_screenshot\": true,\n \"automation_description\": \"<string>\",\n \"automation_endpoint\": \"<string>\",\n \"post_processing_nodes\": []\n },\n \"description\": \"<string>\",\n \"endpoint_name\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}HTTP API
Add Example
POST
/
api
/
v1
/
add_example
Add Example
curl --request POST \
--url https://api.example.com/api/v1/add_example \
--header 'Content-Type: application/json' \
--header 'x-api-key: <x-api-key>' \
--data '
{
"automation": {
"url": "<string>",
"parameters": {
"input_parameters": {},
"generated_parameters": {},
"secure_parameters": {}
},
"nodes": [
{
"type": "<string>",
"interaction_action": {
"max_tries": 10,
"max_timeout_seconds_per_try": 1,
"verify_before_step": true,
"click_element": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"double_click": false,
"expect_download": false,
"download_filename": "<string>",
"button": "left",
"mouse_click": false,
"mouse_click_deviation": {},
"force": false
},
"input_text": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"input_text": "<string>",
"is_slider": false,
"fill_or_type": "fill",
"press_enter": false,
"click_before_input": true
},
"select_option": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"select_values": [
"<string>"
],
"expect_download": false,
"download_filename": "<string>"
},
"check": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
},
"uncheck": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
},
"hover": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
},
"download_url_as_pdf": {
"download_filename": "<string>",
"url": "<string>"
},
"scroll": {
"down": true,
"amount": -1,
"prompt_instructions": "<string>"
},
"upload_file": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
],
"file_path": "<string>",
"file_url": "<string>"
},
"go_to_url": {
"url": "<string>",
"new_tab": false
},
"go_back": {},
"switch_tab": {
"tab_index": 123
},
"close_current_tab": {},
"close_all_but_last_tab": {},
"close_tabs_until": {
"matching_url": "<string>",
"tab_index": 123
},
"agentic_task": {
"task": "<string>",
"max_steps": 123,
"backend": "browser_use",
"use_vision": false,
"keep_alive": true
},
"close_overlay_popup": {
"task": "\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\n\n---\n\n### 🎯 Goal\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\n\n### 📜 Scope of Target Overlays\nTarget elements include, but are not limited to, the following common types of overlays:\n* Cookie Consent Banners/Modals\n* Privacy Policy Notices\n* Email/Newsletter Sign-up Prompts\n* Age Verification Gates\n* Blocking Promotional Offers\n\n### ⚙️ Action Priority and Rules\n\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\n\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \"Accept,\" \"Agree,\" \"Got it,\" \"Allow All,\" or similar positive confirmation phrases.\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \"Close,\" \"X\" (close icon), \"No Thanks,\" \"Maybe Later,\" \"Skip,\" or \"Continue to site.\"\n3. **Avoidance:** Do **not** input text, or click buttons like \"Sign Up,\" \"Learn More,\" or links that navigate away from the current page (e.g., \"Read Full Policy\"). The goal is solely to dismiss the current obstruction.\n\n### 🛑 Completion State\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\n",
"max_steps": 5,
"backend": "browser_use",
"use_vision": true,
"keep_alive": true
},
"key_press": {
"type": "<string>",
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": false,
"skip_prompt": false,
"assert_locator_presence": false,
"recording_screenshot": "<string>",
"bounding_box_variables": [
"<string>"
]
}
},
"assertion_action": {
"network_call": {
"url_pattern": "<string>",
"header_filter": {}
},
"llm": {
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": [
"screenshot"
],
"extraction_format": {
"assertion_result": "bool",
"assertion_reason": "str"
},
"recording_screenshot": "<string>",
"output_variable_names": [
"<string>"
],
"include_full_page": false
},
"python_script": {
"script": "<string>"
}
},
"extraction_action": {
"unique_identifier": "<string>",
"allow_none": false,
"network_call": {
"url_pattern": "<string>",
"extract_from": "response",
"download_from": "response",
"download_filename": "<string>"
},
"llm": {
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": [
"axtree"
],
"recording_screenshot": "<string>",
"output_variable_names": [
"<string>"
],
"include_full_page": false
},
"python_script": {
"script": "<string>",
"extraction_format": {},
"output_variable_names": [
"<string>"
]
},
"screenshot": {
"filename": "<string>",
"full_page": true
},
"state": {},
"two_fa_action": {
"action": {
"type": "<string>",
"receiver_email_address": "<string>",
"sender_email_address": "<string>",
"integration_email_address": "<string>"
},
"output_variable_name": "<string>",
"instructions": "<string>",
"max_wait_time": 300,
"check_interval": 30,
"start_2fa_time_offset_minutes": 0,
"end_2fa_time_offset_minutes": 0
},
"pdf": {
"filename": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"ocr_coordinates": {
"source_variable": "<string>",
"output_x_variable": "coords_x",
"output_y_variable": "coords_y",
"bounding_box_variables": [
"<string>"
]
},
"locator": {
"command": "<string>",
"output_variable_name": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"vision": {
"prompt": "<string>",
"output_variable_names": [
"<string>"
]
},
"api_call": {
"url": "<string>",
"method": "GET",
"headers": {},
"body": {},
"query_params": {},
"output_variable_names": [
"<string>"
],
"timeout": 30,
"poll_condition": "<string>",
"poll_interval": 5,
"max_poll_attempts": 10
}
},
"python_script_action": {
"execution_code": "<string>"
},
"powershell_action": {
"commands": [
"<string>"
],
"exit_after_commands": true
},
"sleep_action": {
"sleep_time": 123
},
"fail_state_action": {
"failure_message": "Automation completed at one of the failure states."
},
"captcha_action": {
"locator": "<string>",
"secondary_locator": "<string>",
"wait_time": 2,
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-pro",
"config": {}
},
"misc_action": {
"set_variable": {
"name": "<string>",
"value": 123,
"expression": "<string>"
},
"llm_query": {
"output_format": {},
"prompt_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"output_variable_names": [
"<string>"
]
}
},
"human_in_loop_action": {
"max_wait_time": 123
},
"before_sleep_time": 0,
"end_sleep_time": 5,
"expect_new_tab": false,
"max_new_tab_wait_time": 0,
"localized_axtree_string": "<string>"
}
],
"browser_channel": "chromium",
"backend": "browser-use",
"allow_cookies": false,
"max_retries": 0,
"expected_downloads": 0,
"remove_empty_nodes_in_axtree": true,
"take_final_screenshot": true,
"automation_description": "<string>",
"automation_endpoint": "<string>",
"post_processing_nodes": []
},
"description": "<string>",
"endpoint_name": "<string>"
}
'import requests
url = "https://api.example.com/api/v1/add_example"
payload = {
"automation": {
"url": "<string>",
"parameters": {
"input_parameters": {},
"generated_parameters": {},
"secure_parameters": {}
},
"nodes": [
{
"type": "<string>",
"interaction_action": {
"max_tries": 10,
"max_timeout_seconds_per_try": 1,
"verify_before_step": True,
"click_element": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"double_click": False,
"expect_download": False,
"download_filename": "<string>",
"button": "left",
"mouse_click": False,
"mouse_click_deviation": {},
"force": False
},
"input_text": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"input_text": "<string>",
"is_slider": False,
"fill_or_type": "fill",
"press_enter": False,
"click_before_input": True
},
"select_option": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"select_values": ["<string>"],
"expect_download": False,
"download_filename": "<string>"
},
"check": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
},
"uncheck": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
},
"hover": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
},
"download_url_as_pdf": {
"download_filename": "<string>",
"url": "<string>"
},
"scroll": {
"down": True,
"amount": -1,
"prompt_instructions": "<string>"
},
"upload_file": {
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"],
"file_path": "<string>",
"file_url": "<string>"
},
"go_to_url": {
"url": "<string>",
"new_tab": False
},
"go_back": {},
"switch_tab": { "tab_index": 123 },
"close_current_tab": {},
"close_all_but_last_tab": {},
"close_tabs_until": {
"matching_url": "<string>",
"tab_index": 123
},
"agentic_task": {
"task": "<string>",
"max_steps": 123,
"backend": "browser_use",
"use_vision": False,
"keep_alive": True
},
"close_overlay_popup": {
"task": "
The primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.
---
### 🎯 Goal
Clear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.
### 📜 Scope of Target Overlays
Target elements include, but are not limited to, the following common types of overlays:
* Cookie Consent Banners/Modals
* Privacy Policy Notices
* Email/Newsletter Sign-up Prompts
* Age Verification Gates
* Blocking Promotional Offers
### ⚙️ Action Priority and Rules
The agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:
1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \"Accept,\" \"Agree,\" \"Got it,\" \"Allow All,\" or similar positive confirmation phrases.
2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \"Close,\" \"X\" (close icon), \"No Thanks,\" \"Maybe Later,\" \"Skip,\" or \"Continue to site.\"
3. **Avoidance:** Do **not** input text, or click buttons like \"Sign Up,\" \"Learn More,\" or links that navigate away from the current page (e.g., \"Read Full Policy\"). The goal is solely to dismiss the current obstruction.
### 🛑 Completion State
The task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.
",
"max_steps": 5,
"backend": "browser_use",
"use_vision": True,
"keep_alive": True
},
"key_press": {
"type": "<string>",
"xpath": "<string>",
"coordinates": {
"[0]": 123,
"[1]": 123
},
"keyword": "<string>",
"command": "<string>",
"prompt_instructions": "",
"skip_command": False,
"skip_prompt": False,
"assert_locator_presence": False,
"recording_screenshot": "<string>",
"bounding_box_variables": ["<string>"]
}
},
"assertion_action": {
"network_call": {
"url_pattern": "<string>",
"header_filter": {}
},
"llm": {
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": ["screenshot"],
"extraction_format": {
"assertion_result": "bool",
"assertion_reason": "str"
},
"recording_screenshot": "<string>",
"output_variable_names": ["<string>"],
"include_full_page": False
},
"python_script": { "script": "<string>" }
},
"extraction_action": {
"unique_identifier": "<string>",
"allow_none": False,
"network_call": {
"url_pattern": "<string>",
"extract_from": "response",
"download_from": "response",
"download_filename": "<string>"
},
"llm": {
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"source": ["axtree"],
"recording_screenshot": "<string>",
"output_variable_names": ["<string>"],
"include_full_page": False
},
"python_script": {
"script": "<string>",
"extraction_format": {},
"output_variable_names": ["<string>"]
},
"screenshot": {
"filename": "<string>",
"full_page": True
},
"state": {},
"two_fa_action": {
"action": {
"type": "<string>",
"receiver_email_address": "<string>",
"sender_email_address": "<string>",
"integration_email_address": "<string>"
},
"output_variable_name": "<string>",
"instructions": "<string>",
"max_wait_time": 300,
"check_interval": 30,
"start_2fa_time_offset_minutes": 0,
"end_2fa_time_offset_minutes": 0
},
"pdf": {
"filename": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"ocr_coordinates": {
"source_variable": "<string>",
"output_x_variable": "coords_x",
"output_y_variable": "coords_y",
"bounding_box_variables": ["<string>"]
},
"locator": {
"command": "<string>",
"output_variable_name": "<string>",
"extraction_format": {},
"extraction_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash"
},
"vision": {
"prompt": "<string>",
"output_variable_names": ["<string>"]
},
"api_call": {
"url": "<string>",
"method": "GET",
"headers": {},
"body": {},
"query_params": {},
"output_variable_names": ["<string>"],
"timeout": 30,
"poll_condition": "<string>",
"poll_interval": 5,
"max_poll_attempts": 10
}
},
"python_script_action": { "execution_code": "<string>" },
"powershell_action": {
"commands": ["<string>"],
"exit_after_commands": True
},
"sleep_action": { "sleep_time": 123 },
"fail_state_action": { "failure_message": "Automation completed at one of the failure states." },
"captcha_action": {
"locator": "<string>",
"secondary_locator": "<string>",
"wait_time": 2,
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-pro",
"config": {}
},
"misc_action": {
"set_variable": {
"name": "<string>",
"value": 123,
"expression": "<string>"
},
"llm_query": {
"output_format": {},
"prompt_instructions": "<string>",
"llm_provider": "gemini",
"llm_model_name": "gemini-2.5-flash",
"output_variable_names": ["<string>"]
}
},
"human_in_loop_action": { "max_wait_time": 123 },
"before_sleep_time": 0,
"end_sleep_time": 5,
"expect_new_tab": False,
"max_new_tab_wait_time": 0,
"localized_axtree_string": "<string>"
}
],
"browser_channel": "chromium",
"backend": "browser-use",
"allow_cookies": False,
"max_retries": 0,
"expected_downloads": 0,
"remove_empty_nodes_in_axtree": True,
"take_final_screenshot": True,
"automation_description": "<string>",
"automation_endpoint": "<string>",
"post_processing_nodes": []
},
"description": "<string>",
"endpoint_name": "<string>"
}
headers = {
"x-api-key": "<x-api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<x-api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
automation: {
url: '<string>',
parameters: {input_parameters: {}, generated_parameters: {}, secure_parameters: {}},
nodes: [
{
type: '<string>',
interaction_action: {
max_tries: 10,
max_timeout_seconds_per_try: 1,
verify_before_step: true,
click_element: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
double_click: false,
expect_download: false,
download_filename: '<string>',
button: 'left',
mouse_click: false,
mouse_click_deviation: {},
force: false
},
input_text: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
input_text: '<string>',
is_slider: false,
fill_or_type: 'fill',
press_enter: false,
click_before_input: true
},
select_option: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
select_values: ['<string>'],
expect_download: false,
download_filename: '<string>'
},
check: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
},
uncheck: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
},
hover: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
},
download_url_as_pdf: {download_filename: '<string>', url: '<string>'},
scroll: {down: true, amount: -1, prompt_instructions: '<string>'},
upload_file: {
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>'],
file_path: '<string>',
file_url: '<string>'
},
go_to_url: {url: '<string>', new_tab: false},
go_back: {},
switch_tab: {tab_index: 123},
close_current_tab: {},
close_all_but_last_tab: {},
close_tabs_until: {matching_url: '<string>', tab_index: 123},
agentic_task: {
task: '<string>',
max_steps: 123,
backend: 'browser_use',
use_vision: false,
keep_alive: true
},
close_overlay_popup: {
task: '\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\n\n---\n\n### 🎯 Goal\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\n\n### 📜 Scope of Target Overlays\nTarget elements include, but are not limited to, the following common types of overlays:\n* Cookie Consent Banners/Modals\n* Privacy Policy Notices\n* Email/Newsletter Sign-up Prompts\n* Age Verification Gates\n* Blocking Promotional Offers\n\n### ⚙️ Action Priority and Rules\n\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\n\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled "Accept," "Agree," "Got it," "Allow All," or similar positive confirmation phrases.\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like "Close," "X" (close icon), "No Thanks," "Maybe Later," "Skip," or "Continue to site."\n3. **Avoidance:** Do **not** input text, or click buttons like "Sign Up," "Learn More," or links that navigate away from the current page (e.g., "Read Full Policy"). The goal is solely to dismiss the current obstruction.\n\n### 🛑 Completion State\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\n',
max_steps: 5,
backend: 'browser_use',
use_vision: true,
keep_alive: true
},
key_press: {
type: '<string>',
xpath: '<string>',
coordinates: {'[0]': 123, '[1]': 123},
keyword: '<string>',
command: '<string>',
prompt_instructions: '',
skip_command: false,
skip_prompt: false,
assert_locator_presence: false,
recording_screenshot: '<string>',
bounding_box_variables: ['<string>']
}
},
assertion_action: {
network_call: {url_pattern: '<string>', header_filter: {}},
llm: {
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash',
source: ['screenshot'],
extraction_format: {assertion_result: 'bool', assertion_reason: 'str'},
recording_screenshot: '<string>',
output_variable_names: ['<string>'],
include_full_page: false
},
python_script: {script: '<string>'}
},
extraction_action: {
unique_identifier: '<string>',
allow_none: false,
network_call: {
url_pattern: '<string>',
extract_from: 'response',
download_from: 'response',
download_filename: '<string>'
},
llm: {
extraction_format: {},
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash',
source: ['axtree'],
recording_screenshot: '<string>',
output_variable_names: ['<string>'],
include_full_page: false
},
python_script: {script: '<string>', extraction_format: {}, output_variable_names: ['<string>']},
screenshot: {filename: '<string>', full_page: true},
state: {},
two_fa_action: {
action: {
type: '<string>',
receiver_email_address: '<string>',
sender_email_address: '<string>',
integration_email_address: '<string>'
},
output_variable_name: '<string>',
instructions: '<string>',
max_wait_time: 300,
check_interval: 30,
start_2fa_time_offset_minutes: 0,
end_2fa_time_offset_minutes: 0
},
pdf: {
filename: '<string>',
extraction_format: {},
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash'
},
ocr_coordinates: {
source_variable: '<string>',
output_x_variable: 'coords_x',
output_y_variable: 'coords_y',
bounding_box_variables: ['<string>']
},
locator: {
command: '<string>',
output_variable_name: '<string>',
extraction_format: {},
extraction_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash'
},
vision: {prompt: '<string>', output_variable_names: ['<string>']},
api_call: {
url: '<string>',
method: 'GET',
headers: {},
body: JSON.stringify({}),
query_params: {},
output_variable_names: ['<string>'],
timeout: 30,
poll_condition: '<string>',
poll_interval: 5,
max_poll_attempts: 10
}
},
python_script_action: {execution_code: '<string>'},
powershell_action: {commands: ['<string>'], exit_after_commands: true},
sleep_action: {sleep_time: 123},
fail_state_action: {failure_message: 'Automation completed at one of the failure states.'},
captcha_action: {
locator: '<string>',
secondary_locator: '<string>',
wait_time: 2,
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-pro',
config: {}
},
misc_action: {
set_variable: {name: '<string>', value: 123, expression: '<string>'},
llm_query: {
output_format: {},
prompt_instructions: '<string>',
llm_provider: 'gemini',
llm_model_name: 'gemini-2.5-flash',
output_variable_names: ['<string>']
}
},
human_in_loop_action: {max_wait_time: 123},
before_sleep_time: 0,
end_sleep_time: 5,
expect_new_tab: false,
max_new_tab_wait_time: 0,
localized_axtree_string: '<string>'
}
],
browser_channel: 'chromium',
backend: 'browser-use',
allow_cookies: false,
max_retries: 0,
expected_downloads: 0,
remove_empty_nodes_in_axtree: true,
take_final_screenshot: true,
automation_description: '<string>',
automation_endpoint: '<string>',
post_processing_nodes: []
},
description: '<string>',
endpoint_name: '<string>'
})
};
fetch('https://api.example.com/api/v1/add_example', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v1/add_example",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'automation' => [
'url' => '<string>',
'parameters' => [
'input_parameters' => [
],
'generated_parameters' => [
],
'secure_parameters' => [
]
],
'nodes' => [
[
'type' => '<string>',
'interaction_action' => [
'max_tries' => 10,
'max_timeout_seconds_per_try' => 1,
'verify_before_step' => true,
'click_element' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'double_click' => false,
'expect_download' => false,
'download_filename' => '<string>',
'button' => 'left',
'mouse_click' => false,
'mouse_click_deviation' => [
],
'force' => false
],
'input_text' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'input_text' => '<string>',
'is_slider' => false,
'fill_or_type' => 'fill',
'press_enter' => false,
'click_before_input' => true
],
'select_option' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'select_values' => [
'<string>'
],
'expect_download' => false,
'download_filename' => '<string>'
],
'check' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
],
'uncheck' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
],
'hover' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
],
'download_url_as_pdf' => [
'download_filename' => '<string>',
'url' => '<string>'
],
'scroll' => [
'down' => true,
'amount' => -1,
'prompt_instructions' => '<string>'
],
'upload_file' => [
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
],
'file_path' => '<string>',
'file_url' => '<string>'
],
'go_to_url' => [
'url' => '<string>',
'new_tab' => false
],
'go_back' => [
],
'switch_tab' => [
'tab_index' => 123
],
'close_current_tab' => [
],
'close_all_but_last_tab' => [
],
'close_tabs_until' => [
'matching_url' => '<string>',
'tab_index' => 123
],
'agentic_task' => [
'task' => '<string>',
'max_steps' => 123,
'backend' => 'browser_use',
'use_vision' => false,
'keep_alive' => true
],
'close_overlay_popup' => [
'task' => '
The primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.
---
### 🎯 Goal
Clear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.
### 📜 Scope of Target Overlays
Target elements include, but are not limited to, the following common types of overlays:
* Cookie Consent Banners/Modals
* Privacy Policy Notices
* Email/Newsletter Sign-up Prompts
* Age Verification Gates
* Blocking Promotional Offers
### ⚙️ Action Priority and Rules
The agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:
1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled "Accept," "Agree," "Got it," "Allow All," or similar positive confirmation phrases.
2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like "Close," "X" (close icon), "No Thanks," "Maybe Later," "Skip," or "Continue to site."
3. **Avoidance:** Do **not** input text, or click buttons like "Sign Up," "Learn More," or links that navigate away from the current page (e.g., "Read Full Policy"). The goal is solely to dismiss the current obstruction.
### 🛑 Completion State
The task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.
',
'max_steps' => 5,
'backend' => 'browser_use',
'use_vision' => true,
'keep_alive' => true
],
'key_press' => [
'type' => '<string>',
'xpath' => '<string>',
'coordinates' => [
'[0]' => 123,
'[1]' => 123
],
'keyword' => '<string>',
'command' => '<string>',
'prompt_instructions' => '',
'skip_command' => false,
'skip_prompt' => false,
'assert_locator_presence' => false,
'recording_screenshot' => '<string>',
'bounding_box_variables' => [
'<string>'
]
]
],
'assertion_action' => [
'network_call' => [
'url_pattern' => '<string>',
'header_filter' => [
]
],
'llm' => [
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash',
'source' => [
'screenshot'
],
'extraction_format' => [
'assertion_result' => 'bool',
'assertion_reason' => 'str'
],
'recording_screenshot' => '<string>',
'output_variable_names' => [
'<string>'
],
'include_full_page' => false
],
'python_script' => [
'script' => '<string>'
]
],
'extraction_action' => [
'unique_identifier' => '<string>',
'allow_none' => false,
'network_call' => [
'url_pattern' => '<string>',
'extract_from' => 'response',
'download_from' => 'response',
'download_filename' => '<string>'
],
'llm' => [
'extraction_format' => [
],
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash',
'source' => [
'axtree'
],
'recording_screenshot' => '<string>',
'output_variable_names' => [
'<string>'
],
'include_full_page' => false
],
'python_script' => [
'script' => '<string>',
'extraction_format' => [
],
'output_variable_names' => [
'<string>'
]
],
'screenshot' => [
'filename' => '<string>',
'full_page' => true
],
'state' => [
],
'two_fa_action' => [
'action' => [
'type' => '<string>',
'receiver_email_address' => '<string>',
'sender_email_address' => '<string>',
'integration_email_address' => '<string>'
],
'output_variable_name' => '<string>',
'instructions' => '<string>',
'max_wait_time' => 300,
'check_interval' => 30,
'start_2fa_time_offset_minutes' => 0,
'end_2fa_time_offset_minutes' => 0
],
'pdf' => [
'filename' => '<string>',
'extraction_format' => [
],
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash'
],
'ocr_coordinates' => [
'source_variable' => '<string>',
'output_x_variable' => 'coords_x',
'output_y_variable' => 'coords_y',
'bounding_box_variables' => [
'<string>'
]
],
'locator' => [
'command' => '<string>',
'output_variable_name' => '<string>',
'extraction_format' => [
],
'extraction_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash'
],
'vision' => [
'prompt' => '<string>',
'output_variable_names' => [
'<string>'
]
],
'api_call' => [
'url' => '<string>',
'method' => 'GET',
'headers' => [
],
'body' => [
],
'query_params' => [
],
'output_variable_names' => [
'<string>'
],
'timeout' => 30,
'poll_condition' => '<string>',
'poll_interval' => 5,
'max_poll_attempts' => 10
]
],
'python_script_action' => [
'execution_code' => '<string>'
],
'powershell_action' => [
'commands' => [
'<string>'
],
'exit_after_commands' => true
],
'sleep_action' => [
'sleep_time' => 123
],
'fail_state_action' => [
'failure_message' => 'Automation completed at one of the failure states.'
],
'captcha_action' => [
'locator' => '<string>',
'secondary_locator' => '<string>',
'wait_time' => 2,
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-pro',
'config' => [
]
],
'misc_action' => [
'set_variable' => [
'name' => '<string>',
'value' => 123,
'expression' => '<string>'
],
'llm_query' => [
'output_format' => [
],
'prompt_instructions' => '<string>',
'llm_provider' => 'gemini',
'llm_model_name' => 'gemini-2.5-flash',
'output_variable_names' => [
'<string>'
]
]
],
'human_in_loop_action' => [
'max_wait_time' => 123
],
'before_sleep_time' => 0,
'end_sleep_time' => 5,
'expect_new_tab' => false,
'max_new_tab_wait_time' => 0,
'localized_axtree_string' => '<string>'
]
],
'browser_channel' => 'chromium',
'backend' => 'browser-use',
'allow_cookies' => false,
'max_retries' => 0,
'expected_downloads' => 0,
'remove_empty_nodes_in_axtree' => true,
'take_final_screenshot' => true,
'automation_description' => '<string>',
'automation_endpoint' => '<string>',
'post_processing_nodes' => [
]
],
'description' => '<string>',
'endpoint_name' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <x-api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v1/add_example"
payload := strings.NewReader("{\n \"automation\": {\n \"url\": \"<string>\",\n \"parameters\": {\n \"input_parameters\": {},\n \"generated_parameters\": {},\n \"secure_parameters\": {}\n },\n \"nodes\": [\n {\n \"type\": \"<string>\",\n \"interaction_action\": {\n \"max_tries\": 10,\n \"max_timeout_seconds_per_try\": 1,\n \"verify_before_step\": true,\n \"click_element\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"double_click\": false,\n \"expect_download\": false,\n \"download_filename\": \"<string>\",\n \"button\": \"left\",\n \"mouse_click\": false,\n \"mouse_click_deviation\": {},\n \"force\": false\n },\n \"input_text\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"input_text\": \"<string>\",\n \"is_slider\": false,\n \"fill_or_type\": \"fill\",\n \"press_enter\": false,\n \"click_before_input\": true\n },\n \"select_option\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"select_values\": [\n \"<string>\"\n ],\n \"expect_download\": false,\n \"download_filename\": \"<string>\"\n },\n \"check\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"uncheck\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"hover\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"download_url_as_pdf\": {\n \"download_filename\": \"<string>\",\n \"url\": \"<string>\"\n },\n \"scroll\": {\n \"down\": true,\n \"amount\": -1,\n \"prompt_instructions\": \"<string>\"\n },\n \"upload_file\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"file_path\": \"<string>\",\n \"file_url\": \"<string>\"\n },\n \"go_to_url\": {\n \"url\": \"<string>\",\n \"new_tab\": false\n },\n \"go_back\": {},\n \"switch_tab\": {\n \"tab_index\": 123\n },\n \"close_current_tab\": {},\n \"close_all_but_last_tab\": {},\n \"close_tabs_until\": {\n \"matching_url\": \"<string>\",\n \"tab_index\": 123\n },\n \"agentic_task\": {\n \"task\": \"<string>\",\n \"max_steps\": 123,\n \"backend\": \"browser_use\",\n \"use_vision\": false,\n \"keep_alive\": true\n },\n \"close_overlay_popup\": {\n \"task\": \"\\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\\n\\n---\\n\\n### 🎯 Goal\\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\\n\\n### 📜 Scope of Target Overlays\\nTarget elements include, but are not limited to, the following common types of overlays:\\n* Cookie Consent Banners/Modals\\n* Privacy Policy Notices\\n* Email/Newsletter Sign-up Prompts\\n* Age Verification Gates\\n* Blocking Promotional Offers\\n\\n### ⚙️ Action Priority and Rules\\n\\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\\n\\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \\\"Accept,\\\" \\\"Agree,\\\" \\\"Got it,\\\" \\\"Allow All,\\\" or similar positive confirmation phrases.\\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \\\"Close,\\\" \\\"X\\\" (close icon), \\\"No Thanks,\\\" \\\"Maybe Later,\\\" \\\"Skip,\\\" or \\\"Continue to site.\\\"\\n3. **Avoidance:** Do **not** input text, or click buttons like \\\"Sign Up,\\\" \\\"Learn More,\\\" or links that navigate away from the current page (e.g., \\\"Read Full Policy\\\"). The goal is solely to dismiss the current obstruction.\\n\\n### 🛑 Completion State\\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\\n\",\n \"max_steps\": 5,\n \"backend\": \"browser_use\",\n \"use_vision\": true,\n \"keep_alive\": true\n },\n \"key_press\": {\n \"type\": \"<string>\",\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n }\n },\n \"assertion_action\": {\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"header_filter\": {}\n },\n \"llm\": {\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"screenshot\"\n ],\n \"extraction_format\": {\n \"assertion_result\": \"bool\",\n \"assertion_reason\": \"str\"\n },\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\"\n }\n },\n \"extraction_action\": {\n \"unique_identifier\": \"<string>\",\n \"allow_none\": false,\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"extract_from\": \"response\",\n \"download_from\": \"response\",\n \"download_filename\": \"<string>\"\n },\n \"llm\": {\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"axtree\"\n ],\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\",\n \"extraction_format\": {},\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"screenshot\": {\n \"filename\": \"<string>\",\n \"full_page\": true\n },\n \"state\": {},\n \"two_fa_action\": {\n \"action\": {\n \"type\": \"<string>\",\n \"receiver_email_address\": \"<string>\",\n \"sender_email_address\": \"<string>\",\n \"integration_email_address\": \"<string>\"\n },\n \"output_variable_name\": \"<string>\",\n \"instructions\": \"<string>\",\n \"max_wait_time\": 300,\n \"check_interval\": 30,\n \"start_2fa_time_offset_minutes\": 0,\n \"end_2fa_time_offset_minutes\": 0\n },\n \"pdf\": {\n \"filename\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"ocr_coordinates\": {\n \"source_variable\": \"<string>\",\n \"output_x_variable\": \"coords_x\",\n \"output_y_variable\": \"coords_y\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"locator\": {\n \"command\": \"<string>\",\n \"output_variable_name\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"vision\": {\n \"prompt\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"api_call\": {\n \"url\": \"<string>\",\n \"method\": \"GET\",\n \"headers\": {},\n \"body\": {},\n \"query_params\": {},\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"timeout\": 30,\n \"poll_condition\": \"<string>\",\n \"poll_interval\": 5,\n \"max_poll_attempts\": 10\n }\n },\n \"python_script_action\": {\n \"execution_code\": \"<string>\"\n },\n \"powershell_action\": {\n \"commands\": [\n \"<string>\"\n ],\n \"exit_after_commands\": true\n },\n \"sleep_action\": {\n \"sleep_time\": 123\n },\n \"fail_state_action\": {\n \"failure_message\": \"Automation completed at one of the failure states.\"\n },\n \"captcha_action\": {\n \"locator\": \"<string>\",\n \"secondary_locator\": \"<string>\",\n \"wait_time\": 2,\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-pro\",\n \"config\": {}\n },\n \"misc_action\": {\n \"set_variable\": {\n \"name\": \"<string>\",\n \"value\": 123,\n \"expression\": \"<string>\"\n },\n \"llm_query\": {\n \"output_format\": {},\n \"prompt_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n }\n },\n \"human_in_loop_action\": {\n \"max_wait_time\": 123\n },\n \"before_sleep_time\": 0,\n \"end_sleep_time\": 5,\n \"expect_new_tab\": false,\n \"max_new_tab_wait_time\": 0,\n \"localized_axtree_string\": \"<string>\"\n }\n ],\n \"browser_channel\": \"chromium\",\n \"backend\": \"browser-use\",\n \"allow_cookies\": false,\n \"max_retries\": 0,\n \"expected_downloads\": 0,\n \"remove_empty_nodes_in_axtree\": true,\n \"take_final_screenshot\": true,\n \"automation_description\": \"<string>\",\n \"automation_endpoint\": \"<string>\",\n \"post_processing_nodes\": []\n },\n \"description\": \"<string>\",\n \"endpoint_name\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<x-api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/v1/add_example")
.header("x-api-key", "<x-api-key>")
.header("Content-Type", "application/json")
.body("{\n \"automation\": {\n \"url\": \"<string>\",\n \"parameters\": {\n \"input_parameters\": {},\n \"generated_parameters\": {},\n \"secure_parameters\": {}\n },\n \"nodes\": [\n {\n \"type\": \"<string>\",\n \"interaction_action\": {\n \"max_tries\": 10,\n \"max_timeout_seconds_per_try\": 1,\n \"verify_before_step\": true,\n \"click_element\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"double_click\": false,\n \"expect_download\": false,\n \"download_filename\": \"<string>\",\n \"button\": \"left\",\n \"mouse_click\": false,\n \"mouse_click_deviation\": {},\n \"force\": false\n },\n \"input_text\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"input_text\": \"<string>\",\n \"is_slider\": false,\n \"fill_or_type\": \"fill\",\n \"press_enter\": false,\n \"click_before_input\": true\n },\n \"select_option\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"select_values\": [\n \"<string>\"\n ],\n \"expect_download\": false,\n \"download_filename\": \"<string>\"\n },\n \"check\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"uncheck\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"hover\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"download_url_as_pdf\": {\n \"download_filename\": \"<string>\",\n \"url\": \"<string>\"\n },\n \"scroll\": {\n \"down\": true,\n \"amount\": -1,\n \"prompt_instructions\": \"<string>\"\n },\n \"upload_file\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"file_path\": \"<string>\",\n \"file_url\": \"<string>\"\n },\n \"go_to_url\": {\n \"url\": \"<string>\",\n \"new_tab\": false\n },\n \"go_back\": {},\n \"switch_tab\": {\n \"tab_index\": 123\n },\n \"close_current_tab\": {},\n \"close_all_but_last_tab\": {},\n \"close_tabs_until\": {\n \"matching_url\": \"<string>\",\n \"tab_index\": 123\n },\n \"agentic_task\": {\n \"task\": \"<string>\",\n \"max_steps\": 123,\n \"backend\": \"browser_use\",\n \"use_vision\": false,\n \"keep_alive\": true\n },\n \"close_overlay_popup\": {\n \"task\": \"\\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\\n\\n---\\n\\n### 🎯 Goal\\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\\n\\n### 📜 Scope of Target Overlays\\nTarget elements include, but are not limited to, the following common types of overlays:\\n* Cookie Consent Banners/Modals\\n* Privacy Policy Notices\\n* Email/Newsletter Sign-up Prompts\\n* Age Verification Gates\\n* Blocking Promotional Offers\\n\\n### ⚙️ Action Priority and Rules\\n\\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\\n\\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \\\"Accept,\\\" \\\"Agree,\\\" \\\"Got it,\\\" \\\"Allow All,\\\" or similar positive confirmation phrases.\\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \\\"Close,\\\" \\\"X\\\" (close icon), \\\"No Thanks,\\\" \\\"Maybe Later,\\\" \\\"Skip,\\\" or \\\"Continue to site.\\\"\\n3. **Avoidance:** Do **not** input text, or click buttons like \\\"Sign Up,\\\" \\\"Learn More,\\\" or links that navigate away from the current page (e.g., \\\"Read Full Policy\\\"). The goal is solely to dismiss the current obstruction.\\n\\n### 🛑 Completion State\\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\\n\",\n \"max_steps\": 5,\n \"backend\": \"browser_use\",\n \"use_vision\": true,\n \"keep_alive\": true\n },\n \"key_press\": {\n \"type\": \"<string>\",\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n }\n },\n \"assertion_action\": {\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"header_filter\": {}\n },\n \"llm\": {\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"screenshot\"\n ],\n \"extraction_format\": {\n \"assertion_result\": \"bool\",\n \"assertion_reason\": \"str\"\n },\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\"\n }\n },\n \"extraction_action\": {\n \"unique_identifier\": \"<string>\",\n \"allow_none\": false,\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"extract_from\": \"response\",\n \"download_from\": \"response\",\n \"download_filename\": \"<string>\"\n },\n \"llm\": {\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"axtree\"\n ],\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\",\n \"extraction_format\": {},\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"screenshot\": {\n \"filename\": \"<string>\",\n \"full_page\": true\n },\n \"state\": {},\n \"two_fa_action\": {\n \"action\": {\n \"type\": \"<string>\",\n \"receiver_email_address\": \"<string>\",\n \"sender_email_address\": \"<string>\",\n \"integration_email_address\": \"<string>\"\n },\n \"output_variable_name\": \"<string>\",\n \"instructions\": \"<string>\",\n \"max_wait_time\": 300,\n \"check_interval\": 30,\n \"start_2fa_time_offset_minutes\": 0,\n \"end_2fa_time_offset_minutes\": 0\n },\n \"pdf\": {\n \"filename\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"ocr_coordinates\": {\n \"source_variable\": \"<string>\",\n \"output_x_variable\": \"coords_x\",\n \"output_y_variable\": \"coords_y\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"locator\": {\n \"command\": \"<string>\",\n \"output_variable_name\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"vision\": {\n \"prompt\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"api_call\": {\n \"url\": \"<string>\",\n \"method\": \"GET\",\n \"headers\": {},\n \"body\": {},\n \"query_params\": {},\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"timeout\": 30,\n \"poll_condition\": \"<string>\",\n \"poll_interval\": 5,\n \"max_poll_attempts\": 10\n }\n },\n \"python_script_action\": {\n \"execution_code\": \"<string>\"\n },\n \"powershell_action\": {\n \"commands\": [\n \"<string>\"\n ],\n \"exit_after_commands\": true\n },\n \"sleep_action\": {\n \"sleep_time\": 123\n },\n \"fail_state_action\": {\n \"failure_message\": \"Automation completed at one of the failure states.\"\n },\n \"captcha_action\": {\n \"locator\": \"<string>\",\n \"secondary_locator\": \"<string>\",\n \"wait_time\": 2,\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-pro\",\n \"config\": {}\n },\n \"misc_action\": {\n \"set_variable\": {\n \"name\": \"<string>\",\n \"value\": 123,\n \"expression\": \"<string>\"\n },\n \"llm_query\": {\n \"output_format\": {},\n \"prompt_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n }\n },\n \"human_in_loop_action\": {\n \"max_wait_time\": 123\n },\n \"before_sleep_time\": 0,\n \"end_sleep_time\": 5,\n \"expect_new_tab\": false,\n \"max_new_tab_wait_time\": 0,\n \"localized_axtree_string\": \"<string>\"\n }\n ],\n \"browser_channel\": \"chromium\",\n \"backend\": \"browser-use\",\n \"allow_cookies\": false,\n \"max_retries\": 0,\n \"expected_downloads\": 0,\n \"remove_empty_nodes_in_axtree\": true,\n \"take_final_screenshot\": true,\n \"automation_description\": \"<string>\",\n \"automation_endpoint\": \"<string>\",\n \"post_processing_nodes\": []\n },\n \"description\": \"<string>\",\n \"endpoint_name\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/add_example")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<x-api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"automation\": {\n \"url\": \"<string>\",\n \"parameters\": {\n \"input_parameters\": {},\n \"generated_parameters\": {},\n \"secure_parameters\": {}\n },\n \"nodes\": [\n {\n \"type\": \"<string>\",\n \"interaction_action\": {\n \"max_tries\": 10,\n \"max_timeout_seconds_per_try\": 1,\n \"verify_before_step\": true,\n \"click_element\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"double_click\": false,\n \"expect_download\": false,\n \"download_filename\": \"<string>\",\n \"button\": \"left\",\n \"mouse_click\": false,\n \"mouse_click_deviation\": {},\n \"force\": false\n },\n \"input_text\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"input_text\": \"<string>\",\n \"is_slider\": false,\n \"fill_or_type\": \"fill\",\n \"press_enter\": false,\n \"click_before_input\": true\n },\n \"select_option\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"select_values\": [\n \"<string>\"\n ],\n \"expect_download\": false,\n \"download_filename\": \"<string>\"\n },\n \"check\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"uncheck\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"hover\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"download_url_as_pdf\": {\n \"download_filename\": \"<string>\",\n \"url\": \"<string>\"\n },\n \"scroll\": {\n \"down\": true,\n \"amount\": -1,\n \"prompt_instructions\": \"<string>\"\n },\n \"upload_file\": {\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ],\n \"file_path\": \"<string>\",\n \"file_url\": \"<string>\"\n },\n \"go_to_url\": {\n \"url\": \"<string>\",\n \"new_tab\": false\n },\n \"go_back\": {},\n \"switch_tab\": {\n \"tab_index\": 123\n },\n \"close_current_tab\": {},\n \"close_all_but_last_tab\": {},\n \"close_tabs_until\": {\n \"matching_url\": \"<string>\",\n \"tab_index\": 123\n },\n \"agentic_task\": {\n \"task\": \"<string>\",\n \"max_steps\": 123,\n \"backend\": \"browser_use\",\n \"use_vision\": false,\n \"keep_alive\": true\n },\n \"close_overlay_popup\": {\n \"task\": \"\\nThe primary goal of this task is to **automatically dismiss obstructing overlay popups** to enable a human-like, unobstructed view and interaction with the main website content.\\n\\n---\\n\\n### 🎯 Goal\\nClear the entire viewport of any modal, overlay, or blocking element that prevents access to the underlying webpage content.\\n\\n### 📜 Scope of Target Overlays\\nTarget elements include, but are not limited to, the following common types of overlays:\\n* Cookie Consent Banners/Modals\\n* Privacy Policy Notices\\n* Email/Newsletter Sign-up Prompts\\n* Age Verification Gates\\n* Blocking Promotional Offers\\n\\n### ⚙️ Action Priority and Rules\\n\\nThe agent must only dismiss overlays that a typical human user would close to proceed with the site. The actions must follow these specific rules in order of priority:\\n\\n1. **Cookie Consent:** When encountering a cookie or privacy consent overlay, **always accept** or agree to the policy. Click buttons labeled \\\"Accept,\\\" \\\"Agree,\\\" \\\"Got it,\\\" \\\"Allow All,\\\" or similar positive confirmation phrases.\\n2. **General Dismissal:** For all other overlays (sign-ups, promotions, etc.), prioritize clicking **dismissive buttons** that close the popup without requiring user input. Look for labels like \\\"Close,\\\" \\\"X\\\" (close icon), \\\"No Thanks,\\\" \\\"Maybe Later,\\\" \\\"Skip,\\\" or \\\"Continue to site.\\\"\\n3. **Avoidance:** Do **not** input text, or click buttons like \\\"Sign Up,\\\" \\\"Learn More,\\\" or links that navigate away from the current page (e.g., \\\"Read Full Policy\\\"). The goal is solely to dismiss the current obstruction.\\n\\n### 🛑 Completion State\\nThe task is considered complete when the main body of the webpage is fully visible and ready for a user to interact with, meaning **no active overlays** are obstructing the content.\\n\",\n \"max_steps\": 5,\n \"backend\": \"browser_use\",\n \"use_vision\": true,\n \"keep_alive\": true\n },\n \"key_press\": {\n \"type\": \"<string>\",\n \"xpath\": \"<string>\",\n \"coordinates\": {\n \"[0]\": 123,\n \"[1]\": 123\n },\n \"keyword\": \"<string>\",\n \"command\": \"<string>\",\n \"prompt_instructions\": \"\",\n \"skip_command\": false,\n \"skip_prompt\": false,\n \"assert_locator_presence\": false,\n \"recording_screenshot\": \"<string>\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n }\n },\n \"assertion_action\": {\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"header_filter\": {}\n },\n \"llm\": {\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"screenshot\"\n ],\n \"extraction_format\": {\n \"assertion_result\": \"bool\",\n \"assertion_reason\": \"str\"\n },\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\"\n }\n },\n \"extraction_action\": {\n \"unique_identifier\": \"<string>\",\n \"allow_none\": false,\n \"network_call\": {\n \"url_pattern\": \"<string>\",\n \"extract_from\": \"response\",\n \"download_from\": \"response\",\n \"download_filename\": \"<string>\"\n },\n \"llm\": {\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"source\": [\n \"axtree\"\n ],\n \"recording_screenshot\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"include_full_page\": false\n },\n \"python_script\": {\n \"script\": \"<string>\",\n \"extraction_format\": {},\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"screenshot\": {\n \"filename\": \"<string>\",\n \"full_page\": true\n },\n \"state\": {},\n \"two_fa_action\": {\n \"action\": {\n \"type\": \"<string>\",\n \"receiver_email_address\": \"<string>\",\n \"sender_email_address\": \"<string>\",\n \"integration_email_address\": \"<string>\"\n },\n \"output_variable_name\": \"<string>\",\n \"instructions\": \"<string>\",\n \"max_wait_time\": 300,\n \"check_interval\": 30,\n \"start_2fa_time_offset_minutes\": 0,\n \"end_2fa_time_offset_minutes\": 0\n },\n \"pdf\": {\n \"filename\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"ocr_coordinates\": {\n \"source_variable\": \"<string>\",\n \"output_x_variable\": \"coords_x\",\n \"output_y_variable\": \"coords_y\",\n \"bounding_box_variables\": [\n \"<string>\"\n ]\n },\n \"locator\": {\n \"command\": \"<string>\",\n \"output_variable_name\": \"<string>\",\n \"extraction_format\": {},\n \"extraction_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\"\n },\n \"vision\": {\n \"prompt\": \"<string>\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n },\n \"api_call\": {\n \"url\": \"<string>\",\n \"method\": \"GET\",\n \"headers\": {},\n \"body\": {},\n \"query_params\": {},\n \"output_variable_names\": [\n \"<string>\"\n ],\n \"timeout\": 30,\n \"poll_condition\": \"<string>\",\n \"poll_interval\": 5,\n \"max_poll_attempts\": 10\n }\n },\n \"python_script_action\": {\n \"execution_code\": \"<string>\"\n },\n \"powershell_action\": {\n \"commands\": [\n \"<string>\"\n ],\n \"exit_after_commands\": true\n },\n \"sleep_action\": {\n \"sleep_time\": 123\n },\n \"fail_state_action\": {\n \"failure_message\": \"Automation completed at one of the failure states.\"\n },\n \"captcha_action\": {\n \"locator\": \"<string>\",\n \"secondary_locator\": \"<string>\",\n \"wait_time\": 2,\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-pro\",\n \"config\": {}\n },\n \"misc_action\": {\n \"set_variable\": {\n \"name\": \"<string>\",\n \"value\": 123,\n \"expression\": \"<string>\"\n },\n \"llm_query\": {\n \"output_format\": {},\n \"prompt_instructions\": \"<string>\",\n \"llm_provider\": \"gemini\",\n \"llm_model_name\": \"gemini-2.5-flash\",\n \"output_variable_names\": [\n \"<string>\"\n ]\n }\n },\n \"human_in_loop_action\": {\n \"max_wait_time\": 123\n },\n \"before_sleep_time\": 0,\n \"end_sleep_time\": 5,\n \"expect_new_tab\": false,\n \"max_new_tab_wait_time\": 0,\n \"localized_axtree_string\": \"<string>\"\n }\n ],\n \"browser_channel\": \"chromium\",\n \"backend\": \"browser-use\",\n \"allow_cookies\": false,\n \"max_retries\": 0,\n \"expected_downloads\": 0,\n \"remove_empty_nodes_in_axtree\": true,\n \"take_final_screenshot\": true,\n \"automation_description\": \"<string>\",\n \"automation_endpoint\": \"<string>\",\n \"post_processing_nodes\": []\n },\n \"description\": \"<string>\",\n \"endpoint_name\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Was this page helpful?
⌘I