Skip to main content
Glama

apex_add_dynamic_action

Adds a dynamic action to an Oracle APEX page, handling client-side events like click, change, or page load with actions (JavaScript, submit, show/hide, refresh, PL/SQL).

Instructions

Add a dynamic action (client-side event handler). Actions: execute_javascript, set_value, refresh, show, hide, submit.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
eventNoTriggering event: - "click": Button/element click (default) - "change": Item value change - "page-load": On page load (DOMReady) - "keydown": Key pressed - "custom": Custom jQuery eventclick
da_nameYesDynamic Action name.
page_idYesPage ID.
sequenceNoOrder of execution.
plsql_codeNoPL/SQL for action_type="plsql" (TRUE branch).
action_typeNoWhat the DA does (TRUE branch): - "execute_javascript": Run JavaScript code (use javascript_code param) - "submit_page": Submit the page - "set_value": Set an item value - "show": Show element - "hide": Hide element - "enable": Enable item - "disable": Disable item - "refresh": Refresh a region - "plsql": Execute PL/SQL (use plsql_code param) — runs via AJAXexecute_javascript
fire_on_initNoAlso fire when page first loads.
javascript_codeNoJavaScript to execute (TRUE branch). Has access to apex.item(), apex.server.process().
trigger_elementNoItem name, button name, or jQuery selector that triggers the DA. Leave empty for page-level events (page-load).
affected_elementNoItem or region name affected by the action (TRUE branch).
false_action_typeNoAction type for the FALSE branch (same values as action_type). When provided, a FALSE branch action is created alongside the TRUE branch. Example: use action_type="show" and false_action_type="hide" for conditional show/hide based on a condition expression.
false_javascript_codeNoJavaScript code for the FALSE branch (used when false_action_type="execute_javascript").
false_affected_elementNoItem or region name affected by the FALSE branch action.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations are all false, so the description adds some context by stating it is a client-side event handler. However, it does not disclose behaviors like whether an existing DA with the same name is overwritten, whether changes are persistent, or any prerequisites such as needing an existing page or active app session.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, front-loaded sentence that efficiently conveys the core purpose. It avoids unnecessary detail or repetition, making it easy to scan.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (13 parameters, TRUE/FALSE branches), the description is minimal. It does not mention the TRUE/FALSE branch concept, conditional execution, or prerequisites like an existing page_id or active app. The output schema exists, so return values are not needed, but the conceptual model is under-explained.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the description adds little beyond what the schema already explains. The partial list of actions is potentially misleading: it uses 'submit' while the schema defines 'submit_page', and it omits other action types like 'enable', 'disable', and 'plsql'. This introduces inconsistency rather than adding value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action: 'Add a dynamic action' and clarifies it as a 'client-side event handler', which directly distinguishes it from other 'apex_add_*' tools. Listing example action types reinforces the purpose without ambiguity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies when to use it (client-side interactivity) but does not explicitly state when not to use it or reference alternative tools (e.g., apex_add_process for server-side logic). It lacks explicit usage boundaries, but the context is reasonably clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/TechFernandesLTDA/apex-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server