Skip to main content
tnesh
Staff & Editor
Staff & Editor
Nov 6, 2023 5:48 AM UTC

Technical Tip: How to run a proxy API call from FortiManager to a managed FortiGate

  • Apr 24, 2026 3:28 PM UTC
  • 0 replies
  • 5675 views
  • Translate All
Description

 

This article describes how to run a proxy API call from FortiManager to a managed FortiGate to collect data.

 

Scope

 

FortiManager and FortiGate.

 

Solution

 

  1. FortiManager will send proxy API calls via url:"sys/proxy/json" to managed FortiGate API "resource": "<FortiGate API Call>" via the FGFM tunnel that established between the FortiManager and the managed FortiGate.

Note:

For a complete list of FortiGate API calls, refer to Fortinet Development Network (FNDN):

 

{
     "id" : "1",
     "method": "exec",
     "params": [
         {
             "url": "sys/proxy/json",
             "data": {
                   "target": [ "device/<device-name>" ],
                   "action": "get",
                   "resource": "<FortiGate API Call>"
             }
         }
     ],
     "session" : "<session-id>"
}

 

 

  1. Below are two sample usages of proxy calls from FortiManager to a managed FortiGate:

 

  • Get FortiGate Firewall Address:

 

{
     "id" : "1",
     "method": "exec",
     "params": [
         {
             "url": "sys/proxy/json",
             "data": {
                   "target": [ "device/lab-fgt2" ],
                   "action": "get",
                   "resource": "/api/v2/cmdb/firewall/address"
             }
         }
     ],
     "session" : "{{session-id}}"
}

 

 

fmg-get-address.png

 

 

  • Get FortiGate License Info:

 

{
     "id" : "1",
     "method": "exec",
     "params": [
         {
             "url": "sys/proxy/json",
             "data": {
                   "target": [ "device/lab-fgt2" ],
                   "action": "get",
                   "resource": "/api/v2/monitor/license/status"
             }
         }
     ],
     "session" : "{{session-id}}"
}

 


fmg-get-license-status.png

 

 

Related articles:

Risk and Resilience in the Age of AI. An OT Thought Leadership Summit for Houston's Critical Infrastructure Leaders. Date: Thursday, December 3, 2026. Time: 8:30 am - 1:30 pm (CT). Location: The Westin Houston, Memorial City | 945 Gessner Road, Houston, TX 77024