HellScript Syntax
Complete language syntax reference
Workflow Declaration
workflow "Workflow Name" {
version = "1.0.0"
mode = browser_automation // or http_only
timeout = 300 // seconds
retry_count = 3
// Parameters
param name: String
param count: Number = 10
// Steps
step "Step Name" {
// actions
}
}Data Types
- •
String- Text values - •
Number- Integers and floats - •
Boolean- true/false - •
Object- Key-value pairs - •
Array- Lists of values
Variables
var name: String = "value"
var count: Number = 42
var enabled: Boolean = true
var data: Object = { key: "value" }
var items: Array = [1, 2, 3]Control Flow
If/Else
if (condition) {
// actions
} else if (other_condition) {
// actions
} else {
// actions
}Loops
for (item in items) {
console.log(item)
}
while (condition) {
// actions
break // or continue
}Error Handling
try {
click(".submit-button")
} catch (error) {
console.error("Button click failed:", error)
retry {
wait(1000)
click(".submit-button")
}
}Functions
function processData(input: String): String {
var result = input.toUpperCase()
return result
}
var output = processData("hello")Module Imports
import @stdlib/http
import @myorg/custom-module@1.0.0
workflow "Using Modules" {
step "Call module" {
var result = custom_module.process()
}
}Comments
// Single line comment /* * Multi-line * comment */