nui_act
Simulate clicks, typing, key presses, hovering, or scrolling on a FiveM resource's NUI. Target elements by snapshot ref, CSS selector, or visible text and get a fresh snapshot back.
Instructions
Act on a resource's NUI: click, hover, type (value; submit presses Enter), key (value, e.g. Escape) or scroll (value = pixels). Target by ref from nui_snapshot, CSS selector or visible text. Returns a fresh snapshot.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"resource": "<resource>",
"action": "<action>"
},
"name": "nui_act"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | ||
| text | No | ||
| value | No | ||
| action | Yes | ||
| submit | No | ||
| resource | Yes | ||
| selector | No | ||
| settleMs | No | ||
| snapshot | No |