Skip to main content
Rahulv
Staff
Staff
Jun 15, 2022 2:24 AM UTC

Technical Tip: Create immediate maintenance via API

  • Apr 24, 2026 3:05 PM UTC
  • 0 replies
  • 539 views
  • Translate All
Description

This article describes how to create immediate maintenance via API.

Scope

FortiMonitor, Maintenance via API.

Solution

FortiMonitor offers API functionality and with that, users can perform different operations.

For example, creating/deleting/viewing instances, fetching and creating users' details, creating/viewing maintenance, etc.

 

To view the API collection and how it works, refer to the document.

 

Creating immediate maintenance via API can be quite handy.

Below is an example, of the JSON query which can be executed through the FortiMonitor's swagger-based API page. 

 

The mandatory fields are:

1) Name.

2) Target (if it's for a specific instance).

3) Either use "Duration" (describes for how long the maintenance should be active) or use "original_end_time" (parameter value must be in UTC, following the format: YYYY-MM-DD HH:MM:SS).

JSON request body: 

 

{   "description": "test-maintenance",    "disrupt_active_outages": true,    "duration": 10,    "exclude_from_availability": true,    "individual_targets": null,    "monitoring": "no_alerts",    "name": "Test-API",    "notification_schedule": null,    "original_end_time": null,    "original_start_time": null,    "pause_all_checks": null,    "recurrence_interval": 1,    "recurrence_type": null,    "show_in_public_report": true,    "tags": null,    "targets": ["https://api2.panopta.com/v2/server/<server_id>"],    "weekdays": null }

 

With the above example, if by entering the server_id, users should be able to add immediate maintenance which will be active for 10 minutes.

Note.

If using Postman or invoking the API through code, refer to the documentation for more details.

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