Skip to main content
Glama

Opsphere — DevOps & SRE Intelligence

Cloudflare: Origin Rules replace

cf_origin_rules_replace
Destructive

Replace Origin Rules entrypoint with the provided full rules array.

Input Schema

NameRequiredDescriptionDefault
zoneYesZone name (e.g. your-tenant.com) or zone ID
rulesYesComplete Cloudflare origin rules array
context_idNoOptional explicit Connection Hub work context (ctx_*). Omit to use the conversation's active workspace; global Hub tools ignore it.
descriptionNo
account_slugNoCloudflare account slug. Required when the workspace has multiple accounts and the zone is not yet cataloged.
environment_slugNoCloud Catalog environment used as an account-routing preference when no zone is provided.

Output Schema

NameRequiredDescriptionDefault
okYes
dataYes
contractVersionYes
dataSchemaVersionYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed25 schema fields changed
    • changedOutput schema / properties / data / additionalProperties
      Previous value: -trueNew value: +false
    • removedOutput schema / properties / data / properties / count
      Removed value: -{
      -  "type": "number"
      -}
    • addedOutput schema / properties / data / properties / description
      Added value: +{
      +  "type": "string"
      +}
    • removedOutput schema / properties / data / properties / errors / items / $ref
      Removed value: -"#/properties/data/properties/result/anyOf/0/items"
    • addedOutput schema / properties / data / properties / errors / items / additionalProperties
      Added value: +false
    • addedOutput schema / properties / data / properties / errors / items / properties
      Added value: +{
      +  "code": {
      +    "type": "integer"
      +  },
      +  "message": {
      +    "type": "string"
      +  }
      +}
    • addedOutput schema / properties / data / properties / errors / items / required
      Added value: +[
      +  "message"
      +]
    • addedOutput schema / properties / data / properties / errors / items / type
      Added value: +"object"
    • addedOutput schema / properties / data / properties / gaps
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / data / properties / id
      Added value: +{
      +  "type": "string"
      +}
    • removedOutput schema / properties / data / properties / items
      Removed value: -{
      -  "$ref": "#/properties/data/properties/result/anyOf/0"
      -}
    • addedOutput schema / properties / data / properties / lastUpdated
      Added value: +{
      +  "format": "date-time",
      +  "type": "string"
      +}
    • removedOutput schema / properties / data / properties / messages
      Removed value: -{
      -  "items": {
      -    "anyOf": [
      -      {
      -        "type": "string"
      -      },
      -      {
      -        "$ref": "#/properties/data/properties/result/anyOf/0/items"
      -      }
      -    ]
      -  },
      -  "type": "array"
      -}
    • addedOutput schema / properties / data / properties / name
      Added value: +{
      +  "type": "string"
      +}
    • addedOutput schema / properties / data / properties / partial
      Added value: +{
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / data / properties / phase
      Added value: +{
      +  "type": "string"
      +}
    • removedOutput schema / properties / data / properties / result
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "items": {
      -        "additionalProperties": true,
      -        "properties": {},
      -        "type": "object"
      -      },
      -      "type": "array"
      -    },
      -    {
      -      "$ref": "#/properties/data/properties/result/anyOf/0/items"
      -    }
      -  ]
      -}
    • removedOutput schema / properties / data / properties / result_info
      Removed value: -{
      -  "$ref": "#/properties/data/properties/result/anyOf/0/items"
      -}
    • addedOutput schema / properties / data / properties / rules
      Added value: +{
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "action": {
      +        "type": "string"
      +      },
      +      "childRulesetId": {
      +        "type": "string"
      +      },
      +      "description": {
      +        "type": "string"
      +      },
      +      "enabled": {
      +        "type": "boolean"
      +      },
      +      "expression": {
      +        "type": "string"
      +      },
      +      "id": {
      +        "type": "string"
      +      },
      +      "ref": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "id",
      +      "enabled"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / data / properties / truncated
      Added value: +{
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / data / properties / version
      Added value: +{
      +  "type": "string"
      +}
    • addedOutput schema / properties / data / properties / warnings
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedOutput schema / properties / data / required
      Added value: +[
      +  "rules",
      +  "partial",
      +  "truncated",
      +  "warnings",
      +  "gaps"
      +]
    • addedOutput schema / properties / dataSchemaVersion
      Added value: +{
      +  "const": 2,
      +  "type": "number"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "contractVersion",
      -  "ok",
      -  "data"
      -]New value: +[
      +  "contractVersion",
      +  "dataSchemaVersion",
      +  "ok",
      +  "data"
      +]
  2. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, so the agent knows this overwrites state. The description reinforces this with 'Replace ... full rules array', but adds no detail on what gets destroyed (omitted rules are removed), whether it's reversible, ordering/precedence effects, or any rate limits/permission requirements.

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?

A single front-loaded sentence with no filler, and the verb and payload expectation come first. Its brevity borders on under-specification for a destructive tool, but nothing is wasted.

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?

An output schema exists, so return values need no explanation. Still, for a destructive, open-world mutation with 6 parameters, the description omits the practical consequences of the wholesale replace, any prerequisite to fetch current rules, and account/zone routing caveats already implied by the schema.

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?

Schema coverage is 83%, so the schema already documents zone, context_id, account_slug, and environment_slug. The description only touches 'rules', and the schema's own text ('Complete Cloudflare origin rules array') already conveys the completeness requirement, so added meaning is marginal.

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

Purpose4/5

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

States a specific verb ('Replace') and a specific resource ('Origin Rules entrypoint'), which distinguishes it from the read-only sibling cf_origin_rules_list. It does not, however, differentiate itself from other write-path siblings such as cf_ruleset_entrypoint_update or cf_config_rules_replace.

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 phrase 'provided full rules array' implies a precondition (you must supply the complete set, not a delta), which is useful guidance. But there is no explicit when-to-use vs. when-not, no mention of reading existing rules via cf_origin_rules_list first, and no named alternative.

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