Skip to main content
Glama

apex_add_global_js

Add global JavaScript to all pages in Oracle APEX by injecting code into Page 0.

Instructions

Add global JavaScript to all pages via Page 0.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
descriptionNoDescription of what this JS does.
function_nameYesFunction name / identifier (e.g., "TEA_UTILS"). Used only as a label; the JS itself can define multiple functions.
javascript_codeYesThe full JavaScript code. Can be multiple functions. Will be wrapped in an IIFE to avoid polluting global scope unless the code already starts with '(' or 'var '/'let '/'const '.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

Annotations provide no safety hints (all false), and the description does not disclose behavioral traits like whether JS is appended or replaces existing code, permission needs, or lifecycle effects. 'Via Page 0' gives implementation context but not side-effect transparency.

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?

Single concise sentence, front-loaded with action and scope. Every word contributes meaning with no redundancy.

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

Completeness2/5

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

For a mutation tool affecting all pages, the description lacks behavior details (append/replace, permissions, cleanup) and does not mention output or side effects despite having an output schema. The one-liner is insufficient for an agent to anticipate consequences.

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

Parameters3/5

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

Input schema covers all three parameters with descriptions (100% coverage), so baseline 3 applies. The description adds no extra semantic detail beyond naming the global scope.

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?

Clear verb 'Add' and specific resource 'global JavaScript' with scope 'all pages via Page 0'. Differentiates from sibling apex_add_page_js (page-specific) and apex_add_global_css (CSS).

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?

Implied usage for global JS across all pages vs page-specific alternatives, but no explicit when/when-not or alternative references. Missing exclusions for edge cases like needing page-specific JS or when Page 0 might not suffice.

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