Fortinet black logo

Injecting with the FortiOS API

Injecting with the FortiOS API

The FortiOS API method is useful for automating the migration of existing FortiGate-VM instances into Flex-VM. The Flex-VM API and documentation are available on the Fortinet Developer Network website.

Example: Inject a license via HTTP method:
<user_email>:~# curl -k --request POST 'http://<IP_address>/api/v2/monitor/system/vmlicense/download?token=<token_ID>&access_token=<access_token>'
{
  "http_method":"POST",
  "status":"success",
  "http_status":200,
  "vdom":"root",
  "path":"system",
  "name":"vmlicense",
  "action":"download",
  "serial":"<serial_number>",
  "version":"v7.2.0",
  "build":1157
Example: Inject a license via proxy URL:
<user_email>:~# curl -k --request POST 'https://<IP_address>/api/v2/monitor/system/vmlicense/download?token=<token_ID>&proxy_url=<proxy_URL>&access_token=<token>'
{
  "http_method":"POST",
  "status":"success",
  "http_status":200,
  "vdom":"root",
  "path":"system",
  "name":"vmlicense",
  "action":"download",
  "serial":"<serial_number>",
  "version":"v7.2.0",
  "build":1157
}<user_email>:~#

Injecting with the FortiOS API

The FortiOS API method is useful for automating the migration of existing FortiGate-VM instances into Flex-VM. The Flex-VM API and documentation are available on the Fortinet Developer Network website.

Example: Inject a license via HTTP method:
<user_email>:~# curl -k --request POST 'http://<IP_address>/api/v2/monitor/system/vmlicense/download?token=<token_ID>&access_token=<access_token>'
{
  "http_method":"POST",
  "status":"success",
  "http_status":200,
  "vdom":"root",
  "path":"system",
  "name":"vmlicense",
  "action":"download",
  "serial":"<serial_number>",
  "version":"v7.2.0",
  "build":1157
Example: Inject a license via proxy URL:
<user_email>:~# curl -k --request POST 'https://<IP_address>/api/v2/monitor/system/vmlicense/download?token=<token_ID>&proxy_url=<proxy_URL>&access_token=<token>'
{
  "http_method":"POST",
  "status":"success",
  "http_status":200,
  "vdom":"root",
  "path":"system",
  "name":"vmlicense",
  "action":"download",
  "serial":"<serial_number>",
  "version":"v7.2.0",
  "build":1157
}<user_email>:~#