Skip to main content

Execute Advanced Cloudflare API Request

Immutable Catalog Entry

This descriptor comes from the active versioned Portal catalog.

DESTRUCTIVEcloudflare.cloudflare_api_request
  • Contract tier: legacy
  • Risk: destructive
  • Catalog version: 2026.07.12.1
  • Descriptor hash: a9765503b8fd6de67c8cbd124d2773e7bdf146f37e525aabfde693ec6cd30897

Advanced compatibility tool for executing one documented Cloudflare REST method and path with a request-scoped provider credential. This single dispatcher spans read, write, and destructive operations, so it is intentionally excluded from default agent discovery and must never be treated as one uniformly safe risk. Writes require confirm_write=true; destructive operations also require confirm_destructive=true after explicit user approval.

Request Body

{
"jsonrpc": "2.0",
"id": "cloudflare-cloudflare-api-request-example",
"method": "tools/call",
"params": {
"name": "cloudflare.cloudflare_api_request",
"arguments": {
"method": "GET",
"path": "path_example",
"body": "",
"query": "",
"confirm_write": false,
"timeout_seconds": 1,
"max_response_bytes": 1,
"confirm_destructive": false
}
}
}

Arguments Schema

{
"type": "object",
"required": [
"method",
"path"
],
"properties": {
"body": {
"anyOf": [
{
"anyOf": [
{
"type": "object",
"additionalProperties": true
},
{
"type": "array",
"items": {}
}
],
"description": "Provider JSON body for a documented write operation."
},
{
"type": "null"
}
],
"default": null,
"description": "Provider JSON body for a documented write operation."
},
"path": {
"type": "string",
"minLength": 1,
"description": "Cloudflare /client/v4 API path with real IDs substituted, or a full https://api.cloudflare.com/client/v4 URL."
},
"query": {
"anyOf": [
{
"type": "object",
"description": "Provider query-string parameters.",
"additionalProperties": true
},
{
"type": "null"
}
],
"default": null,
"description": "Provider query-string parameters."
},
"method": {
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE"
],
"type": "string",
"description": "Cloudflare REST method to execute."
},
"confirm_write": {
"type": "boolean",
"default": false,
"description": "Must be true for any operation classified write or destructive."
},
"timeout_seconds": {
"type": "number",
"default": 30,
"maximum": 120,
"minimum": 1,
"description": "Provider request timeout in seconds, from 1 through 120."
},
"max_response_bytes": {
"type": "integer",
"default": 100000,
"minimum": 1000,
"description": "Maximum redacted provider payload bytes to return."
},
"confirm_destructive": {
"type": "boolean",
"default": false,
"description": "Must be true in addition to confirm_write for destructive operations after explicit user approval."
}
},
"description": "Advanced mixed-risk Cloudflare REST request contract.",
"additionalProperties": false
}

Output Schema

{
"type": "object",
"required": [
"ok",
"status_code",
"cloudflare_success",
"method",
"path",
"classification",
"covered_by_schema",
"operation",
"response",
"error"
],
"properties": {
"ok": {
"type": "boolean",
"description": "True only for a successful HTTP and Cloudflare semantic result."
},
"path": {
"type": "string",
"description": "Normalized Cloudflare API path."
},
"error": {
"anyOf": [
{
"type": "object",
"description": "Safe semantic failure summary when ok is false.",
"additionalProperties": true
},
{
"type": "null"
}
],
"default": null,
"description": "Safe semantic failure summary when ok is false."
},
"method": {
"type": "string",
"description": "Normalized request method."
},
"response": {
"anyOf": [
{
"type": "object",
"additionalProperties": true
},
{
"type": "array",
"items": {}
},
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
}
],
"description": "Secret-redacted and size-bounded provider response."
},
"operation": {
"anyOf": [
{
"type": "object",
"description": "Matched official operation metadata.",
"additionalProperties": true
},
{
"type": "null"
}
],
"default": null,
"description": "Matched official operation metadata."
},
"status_code": {
"type": "integer",
"description": "Cloudflare HTTP status code."
},
"classification": {
"type": "string",
"description": "Schema-derived read, write, or destructive classification."
},
"covered_by_schema": {
"type": "boolean",
"description": "Whether the path matched the official checked-in schema."
},
"cloudflare_success": {
"anyOf": [
{
"type": "boolean",
"description": "Cloudflare response success flag when present."
},
{
"type": "null"
}
],
"default": null,
"description": "Cloudflare response success flag when present."
}
},
"description": "Secret-safe Cloudflare REST response envelope.",
"additionalProperties": false
}

Code Examples

curl -X POST 'https://portal.madpanda3d.com/api/mcp' \
-H 'Authorization: Bearer mad_live_***' \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"id": "cloudflare-cloudflare-api-request-example",
"method": "tools/call",
"params": {
"name": "cloudflare.cloudflare_api_request",
"arguments": {
"method": "GET",
"path": "path_example",
"body": "",
"query": "",
"confirm_write": false,
"timeout_seconds": 1,
"max_response_bytes": 1,
"confirm_destructive": false
}
}
}'

Example Responses

{
"ok": true,
"message": "Tool cloudflare.cloudflare_api_request executed successfully.",
"note": "Response shape varies by MCP tool. Inspect live responses for exact fields."
}