Skip to main content
Glama
Replaced by its MCP Registry listing

This endpoint is listed in the official MCP Registry as Mondovo. If you published it, claim ownership there.

Create a function draft

create_function_draft

Create a new, empty function draft with a name and a description of what it should do. It has no code and does nothing until its code is written (generate_function_code, or by the owner in the site's settings) and it is deployed. Its address slug comes from the name. Set data_access before writing the code, so the code is written to use those collections: a function can read or change ONLY the collections listed there (env.data), and none by default. When it runs it knows who called it (env.caller: the signed-in customer on the site, the journey's contact) and can start the site's journeys for a contact (env.events), e.g. to send an email. runs makes it run by itself every hour or every day, with no customer, to go through records (e.g. "students inactive for 7 days") and start a journey for each.

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": {
      "site_id": "<site_id>",
      "name": "<name>",
      "description": "<description>"
    },
    "name": "create_function_draft"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesDisplay name, e.g. "Quote calculator"
runsNoDefault when_called. hourly / daily: it also runs by itself once deployed
site_idYesThe site, from list_sites
user_goalNoOptional: the user's goal behind this call, in one short sentence of plain words (e.g. "add a page so customers can book tables"). No names, emails or other personal details.
data_accessNoThe site collections this function may read or change. Tell the owner what it can change.
descriptionYesWhat the function should do
daily_hour_utcNoFor runs=daily: the hour it runs, in UTC (default 0). Convert from the owner's time zone.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / daily_hour_utc
      Added value: +{
      +  "description": "For runs=daily: the hour it runs, in UTC (default 0). Convert from the owner's time zone.",
      +  "maximum": 23,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedInput schema / properties / data_access
      Added value: +{
      +  "description": "The site collections this function may read or change. Tell the owner what it can change.",
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "access": {
      +        "description": "\"write\" also allows reading",
      +        "enum": [
      +          "read",
      +          "write"
      +        ],
      +        "type": "string"
      +      },
      +      "collection": {
      +        "description": "A collection on this site (list_collections), e.g. \"loyalty_account\"",
      +        "maxLength": 100,
      +        "minLength": 1,
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "collection",
      +      "access"
      +    ],
      +    "type": "object"
      +  },
      +  "maxItems": 10,
      +  "type": "array"
      +}
    • addedInput schema / properties / runs
      Added value: +{
      +  "description": "Default when_called. hourly / daily: it also runs by itself once deployed",
      +  "enum": [
      +    "when_called",
      +    "hourly",
      +    "daily"
      +  ],
      +  "type": "string"
      +}
  2. Changed1 schema field changed
    • addedInput schema / properties / user_goal
      Added value: +{
      +  "description": "Optional: the user's goal behind this call, in one short sentence of plain words (e.g. \"add a page so customers can book tables\"). No names, emails or other personal details.",
      +  "type": "string"
      +}
  3. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations, the description discloses that the draft is empty and inert until code is written and deployed, that its slug derives from the name, that data_access restricts which collections the function can touch, and that runtime context includes env.caller and env.events. It also explains that runs enables hourly or daily self-execution without a customer.

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

Conciseness4/5

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

The description is front-loaded with the core action and then layers lifecycle, data-access, and scheduling details. It is dense but every sentence contributes useful context for a complex creation tool.

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

Completeness5/5

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

For a complex draft-creation tool with no output schema, the description covers the draft's inert state, required setup order, data-access constraints, runtime environment, and scheduling behavior. It gives an agent enough context to create the draft correctly and understand its downstream implications.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds meaningful semantics for data_access (none by default, only listed collections are accessible) and runs (self-execution schedule). It also notes that the address slug comes from the name, adding context beyond the schema.

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 states a specific verb and resource: 'Create a new, empty function draft with a name and a description.' It also distinguishes the draft from executable code by explaining that it has no code and does nothing until code is written and deployed, which separates it from generate_function_code.

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

Usage Guidelines4/5

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

The description gives clear sequencing guidance: set data_access before writing code, and use generate_function_code or the owner's settings to add code. It does not explicitly state when not to use this tool versus alternatives, but the lifecycle context is strong.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources