AutomationFlowsAI & RAG › Proceedgate Guard Sub-workflow: Costly API

Proceedgate Guard Sub-workflow: Costly API

ProceedGate Guard Sub-workflow: Costly API. Uses executeWorkflowTrigger, httpRequest. Event-driven trigger; 5 nodes.

Event trigger★★☆☆☆ complexity5 nodesExecute Workflow TriggerHTTP Request
AI & RAG Trigger: Event Nodes: 5 Complexity: ★★☆☆☆ Added:

This workflow follows the Execute Workflow Trigger → HTTP Request recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "name": "ProceedGate Guard Sub-workflow: Costly API",
  "nodes": [
    {
      "parameters": {},
      "id": "exec-trigger",
      "name": "Execute Workflow Trigger",
      "type": "n8n-nodes-base.executeWorkflowTrigger",
      "typeVersion": 1,
      "position": [
        200,
        200
      ]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://governor.proceedgate.dev/v1/check",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer REPLACE_WITH_PG_WORKSPACE_KEY"
            },
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "={\n  \"agent_id\": \"n8n-main-agent\",\n  \"task_hash\": \"{{ $json.query || 'default-search' }}\",\n  \"action\": \"tool_call\",\n  \"step_hash\": \"guarded_costly_tool\"\n}",
        "options": {
          "response": {
            "response": {
              "neverError": true
            }
          }
        }
      },
      "id": "pg-check",
      "name": "ProceedGate Check",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4,
      "position": [
        420,
        200
      ]
    },
    {
      "parameters": {
        "conditions": {
          "boolean": [
            {
              "value1": "={{ $json.allowed }}",
              "value2": true
            }
          ]
        }
      },
      "id": "if-node",
      "name": "Allowed?",
      "type": "n8n-nodes-base.if",
      "typeVersion": 1,
      "position": [
        640,
        200
      ]
    },
    {
      "parameters": {
        "url": "https://dummyjson.com/http/200/Costly_API_Mock_Success",
        "options": {}
      },
      "id": "api-call",
      "name": "Costly API Exec (Mock)",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4,
      "position": [
        860,
        100
      ]
    },
    {
      "parameters": {
        "values": {
          "string": [
            {
              "name": "result",
              "value": "Tool execution denied: ProceedGate blocked this call because the task repeated or policy was hit. Please inform the user."
            }
          ]
        },
        "options": {}
      },
      "id": "set-error",
      "name": "Deny Message",
      "type": "n8n-nodes-base.set",
      "typeVersion": 2,
      "position": [
        860,
        320
      ]
    }
  ],
  "connections": {
    "Execute Workflow Trigger": {
      "main": [
        [
          {
            "node": "ProceedGate Check",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ProceedGate Check": {
      "main": [
        [
          {
            "node": "Allowed?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Allowed?": {
      "main": [
        [
          {
            "node": "Costly API Exec (Mock)",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Deny Message",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

ProceedGate Guard Sub-workflow: Costly API. Uses executeWorkflowTrigger, httpRequest. Event-driven trigger; 5 nodes.

Source: https://github.com/loquit-doru/agent-cost-governor/blob/db2aeda2e1b72b7e66f4f5d3258f2cdd07c6dd67/examples/n8n/proceedgate-guard-sub-workflow.json — original creator credit. Request a take-down →

More AI & RAG workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

AI & RAG

Advisor Eliza Agent. Uses httpRequest, executeWorkflowTrigger. Event-driven trigger; 3 nodes.

HTTP Request, Execute Workflow Trigger
AI & RAG

Add Google Drive File to Vector DB Webhook. Uses executeWorkflowTrigger, httpRequest. Event-driven trigger; 2 nodes.

Execute Workflow Trigger, HTTP Request
AI & RAG

🤖🧑‍💻 AI Agent for Top n8n Creators Leaderboard Reporting. Uses httpRequest, executeWorkflowTrigger, readWriteFile, googleDrive. Event-driven trigger; 49 nodes.

HTTP Request, Execute Workflow Trigger, Read Write File +3
AI & RAG

Memorybufferwindow Workflow. Uses emailSend, httpRequest, executeWorkflowTrigger, formTrigger. Event-driven trigger; 45 nodes.

Email Send, HTTP Request, Execute Workflow Trigger +1
AI & RAG

Memorybufferwindow Workflow. Uses telegramTrigger, telegram, executeWorkflowTrigger, httpRequest. Event-driven trigger; 35 nodes.

Telegram Trigger, Telegram, Execute Workflow Trigger +3