<service domain|custom domain>/app/<portal>/api/v3/request_maintenances
Request Maintenance
Automatically creates requests as per given request fields configurations and schedule configuration, ensuring recurring requests are generated systematically. This helps streamline maintenance operations and reduces manual effort.
Attributes
id (long)
Id of this maintenance
subject (string)
Subject of this maintenance[Max-length : 250]
description (html)
Description of this maintenance
impact_details (string)
Description about the impact of this maintenance[Max-length : 250]
email_ids_to_notify (string)
Array of Email ids, which needs to be filled in request created through this maintenance
delete_pre_template_tasks (boolean)
Boolean value indicating whether the pre template tasks need to be deleted
More Attributes Expand all
configuration_items (configuration_item)
Configuration Items for which the maintenance has been raised
repetitive_schedule (calendar_repetitive_schedule)
Indicates the repetitive_schedule of the maintenance
resolution (JSONObject)
A solution for the maintenance, provided by the technician
show attribute
service_approvers (JSONObject)
The configured users will be added to the first stage of approval for the service maintenance. It can be added only by Requesters.
show attribute
total_cost (double)read only
Total Cost is the cumulative value of service cost and the cost of the individual resources selected
is_service (boolean)read only
Boolean value indicating whether this maintenance is a service maintenance or not
Add Request Maintenance
This operation helps to create a Request Maintenance
Mandatory Fields :- subject
Url
Attributes
id (long)
Id of this maintenance
subject (string)
Subject of this maintenance[Max-length : 250]
description (html)
Description of this maintenance
impact_details (string)
Description about the impact of this maintenance[Max-length : 250]
email_ids_to_notify (string)
Array of Email ids, which needs to be filled in request created through this maintenance
delete_pre_template_tasks (boolean)
Boolean value indicating whether the pre template tasks need to be deleted
More Attributes Expand all
configuration_items (configuration_item)
Configuration Items for which the maintenance has been raised
repetitive_schedule (calendar_repetitive_schedule)
Indicates the repetitive_schedule of the maintenance
resolution (JSONObject)
A solution for the maintenance, provided by the technician
show attribute
service_approvers (JSONObject)
The configured users will be added to the first stage of approval for the service maintenance. It can be added only by Requesters.
show attribute
total_cost (double)read only
Total Cost is the cumulative value of service cost and the cost of the individual resources selected
is_service (boolean)read only
Boolean value indicating whether this maintenance is a service maintenance or not
$ curl <service domain|custom domain>/app/<portal>/api/v3/request_maintenances\
-X POST\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"\
-d input_data='{
"request_maintenance": {
"template": {
"id": "4291000000006655"
},
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"priority": {
"id": "4291000000006805"
},
"impact": {
"id": "4291000000008033"
},
"status": {
"id": "4291000000006657"
},
"impact_details": "Impacts Business in many aspects",
"configuration_items": [],
"urgency": {
"id": "4291000000007919"
},
"mode": {
"id": "4291000000006665"
},
"level": {
"id": "4291000000006671"
},
"email_ids_to_notify": [],
"requester": {
"id": "4291000000145236"
},
"assets": [
{
"id": "4291000003115020"
}
],
"site": {
"id": "4291000001327001"
},
"category": {
"id": "4291000002997019"
},
"subcategory": {
"id": "4291000002997021"
},
"technician": {
"id": "4291000000145236"
},
"subject": "Request Maintenance Subject Here",
"description": "Description goes here",
"attachments": [],
"resolution": {
"content": "\u003cdiv class\u003d\"personalize-wrapper\" style\u003d\"font-family: \u0027Zoho Puvi\u0027,Roboto, sans-serif;font-size: 13px;\"\u003e\u003cdiv\u003eResolution for created Maintenance\u003cbr\u003e\u003c/div\u003e\u003c/div\u003e"
},
"department": {
"id": "4291000000006625"
},
"repetitive_schedule": {
"start_time": {
"value": 1742279400000,
"display_value": "Mar 18, 2025 12:00 pm"
},
"frequency": "Weekly",
"is_advanced": true,
"skip_frequency": 0,
"exclude_weekends": false,
"days_of_week": [
3,
5
],
"is_first_day_of_month": false,
"end_after_occurrences": "7"
}
}
}'
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
input_data = {
"request_maintenance": {
"template": {
"id": "4291000000006655"
},
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"priority": {
"id": "4291000000006805"
},
"impact": {
"id": "4291000000008033"
},
"status": {
"id": "4291000000006657"
},
"impact_details": "Impacts Business in many aspects",
"configuration_items": [],
"urgency": {
"id": "4291000000007919"
},
"mode": {
"id": "4291000000006665"
},
"level": {
"id": "4291000000006671"
},
"email_ids_to_notify": [],
"requester": {
"id": "4291000000145236"
},
"assets": [
{
"id": "4291000003115020"
}
],
"site": {
"id": "4291000001327001"
},
"category": {
"id": "4291000002997019"
},
"subcategory": {
"id": "4291000002997021"
},
"technician": {
"id": "4291000000145236"
},
"subject": "Request Maintenance Subject Here",
"description": "Description goes here",
"attachments": [],
"resolution": {
"content": "\u003cdiv class\u003d\"personalize-wrapper\" style\u003d\"font-family: \u0027Zoho Puvi\u0027,Roboto, sans-serif;font-size: 13px;\"\u003e\u003cdiv\u003eResolution for created Maintenance\u003cbr\u003e\u003c/div\u003e\u003c/div\u003e"
},
"department": {
"id": "4291000000006625"
},
"repetitive_schedule": {
"start_time": {
"value": 1742279400000,
"display_value": "Mar 18, 2025 12:00 pm"
},
"frequency": "Weekly",
"is_advanced": true,
"skip_frequency": 0,
"exclude_weekends": false,
"days_of_week": [
3,
5
],
"is_first_day_of_month": false,
"end_after_occurrences": "7"
}
}
};
params = {"input_data": input_data};
response = invokeurl
[
url: url
type: POST
parameters: params
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$input_data = @'
{
"request_maintenance": {
"template": {
"id": "4291000000006655"
},
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"priority": {
"id": "4291000000006805"
},
"impact": {
"id": "4291000000008033"
},
"status": {
"id": "4291000000006657"
},
"impact_details": "Impacts Business in many aspects",
"configuration_items": [],
"urgency": {
"id": "4291000000007919"
},
"mode": {
"id": "4291000000006665"
},
"level": {
"id": "4291000000006671"
},
"email_ids_to_notify": [],
"requester": {
"id": "4291000000145236"
},
"assets": [
{
"id": "4291000003115020"
}
],
"site": {
"id": "4291000001327001"
},
"category": {
"id": "4291000002997019"
},
"subcategory": {
"id": "4291000002997021"
},
"technician": {
"id": "4291000000145236"
},
"subject": "Request Maintenance Subject Here",
"description": "Description goes here",
"attachments": [],
"resolution": {
"content": "\u003cdiv class\u003d\"personalize-wrapper\" style\u003d\"font-family: \u0027Zoho Puvi\u0027,Roboto, sans-serif;font-size: 13px;\"\u003e\u003cdiv\u003eResolution for created Maintenance\u003cbr\u003e\u003c/div\u003e\u003c/div\u003e"
},
"department": {
"id": "4291000000006625"
},
"repetitive_schedule": {
"start_time": {
"value": 1742279400000,
"display_value": "Mar 18, 2025 12:00 pm"
},
"frequency": "Weekly",
"is_advanced": true,
"skip_frequency": 0,
"exclude_weekends": false,
"days_of_week": [
3,
5
],
"is_first_day_of_month": false,
"end_after_occurrences": "7"
}
}
}
'@
$data = @{ 'input_data' = $input_data}
$response = Invoke-RestMethod -Uri $url -Method post -Body $data -Headers $headers
$response
#Python version - 3.10
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
input_data = '''{
"request_maintenance": {
"template": {
"id": "4291000000006655"
},
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"priority": {
"id": "4291000000006805"
},
"impact": {
"id": "4291000000008033"
},
"status": {
"id": "4291000000006657"
},
"impact_details": "Impacts Business in many aspects",
"configuration_items": [],
"urgency": {
"id": "4291000000007919"
},
"mode": {
"id": "4291000000006665"
},
"level": {
"id": "4291000000006671"
},
"email_ids_to_notify": [],
"requester": {
"id": "4291000000145236"
},
"assets": [
{
"id": "4291000003115020"
}
],
"site": {
"id": "4291000001327001"
},
"category": {
"id": "4291000002997019"
},
"subcategory": {
"id": "4291000002997021"
},
"technician": {
"id": "4291000000145236"
},
"subject": "Request Maintenance Subject Here",
"description": "Description goes here",
"attachments": [],
"resolution": {
"content": "\u003cdiv class\u003d\"personalize-wrapper\" style\u003d\"font-family: \u0027Zoho Puvi\u0027,Roboto, sans-serif;font-size: 13px;\"\u003e\u003cdiv\u003eResolution for created Maintenance\u003cbr\u003e\u003c/div\u003e\u003c/div\u003e"
},
"department": {
"id": "4291000000006625"
},
"repetitive_schedule": {
"start_time": {
"value": 1742279400000,
"display_value": "Mar 18, 2025 12:00 pm"
},
"frequency": "Weekly",
"is_advanced": true,
"skip_frequency": 0,
"exclude_weekends": false,
"days_of_week": [
3,
5
],
"is_first_day_of_month": false,
"end_after_occurrences": "7"
}
}
}'''
data = urlencode({"input_data":input_data}).encode()
httprequest = Request(url, headers=headers,data=data, method="POST")
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": {
"status_code": 2000,
"status": "success"
},
"request_maintenance": {
"template": {
"id": "4291000000006655",
"name": "Default Request"
},
"attachments": [],
"request_type": null,
"subject": "Request Maintenance Subject Here",
"description": "Description goes here",
"next_schedule": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"title": "Request Maintenance Subject Here",
"resolution": {
"content": "<div class=\"personalize-wrapper\" style=\"font-family:"Zoho Puvi", Roboto, sans-serif; font-size:13px\"><div>Resolution for created Maintenance<br><\/div><\/div>"
},
"repetitive_schedule": {
"is_advanced": true,
"next_execution_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"ends_on": null,
"days_of_month": null,
"parent_entity": "request_maintenance",
"last_execution_time": null,
"is_first_day_of_month": false,
"frequency": "Weekly",
"days_of_week": [
3,
5
],
"weeks_of_month": null,
"start_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"last_updated_by": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"exclude_weekends": false,
"months_of_year": null,
"day_config_of_month": null,
"last_updated_time": null,
"skip_frequency": "0",
"end_after_occurrences": "7",
"id": "4291000004120008",
"status": "enabled"
},
"mode": {
"internal_name": "E-Mail",
"name": "E-Mail",
"id": "4291000000006665"
},
"is_service": false,
"assets": [
{
"site": {
"id": "4291000001327001"
},
"product": {
"id": "4291000003115016"
},
"product_type": {
"id": "4291000000005925"
},
"name": "a1",
"id": "4291000003115020"
}
],
"configuration_items": [],
"urgency": {
"name": "High",
"id": "4291000000007919"
},
"maintenance_end": "After 7 Occurrences",
"id": "4291000004120001",
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"events": [
{
"end_date": "2025-04-09 12:00",
"event_length": "1",
"rec_type": "week_1___2,4#7",
"module": "request_maintenance",
"is_created": false,
"start_longvalue": "1742279400000",
"maintenance": "4291000004120001",
"start_date": "2025-03-18 12:00"
}
],
"group": null,
"requester": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"created_time": {
"display_value": "Mar 18, 2025 11:12 AM",
"value": "1742276532086"
},
"item": null,
"one_time_schedule": null,
"level": {
"name": "Tier 1",
"id": "4291000000006671"
},
"schedule_frequency": "Weekly",
"impact": {
"name": "Affects Business",
"id": "4291000000008033"
},
"module": {
"api_plural_name": "requests",
"name": "request",
"display_name_plural": "sdp.module.pluralname.request",
"id": "4291000000085038",
"display_name": "Request",
"category": "SYSTEM",
"icon_name": null
},
"sla": null,
"technician": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"id": "4291000001327001"
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"is_vip_user": false,
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"department": {
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"priority": {
"color": "#ff0000",
"name": "High",
"id": "4291000000006805"
},
"created_by": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"udf_fields": {
"udf_ref9": null
},
"repeat_details": "Every 1 week on Tue, Thu ",
"maintenancestate": 1,
"impact_details": "Impacts Business in many aspects",
"category": {
"deleted": false,
"name": "Centenary Court Building Maintenance",
"id": "4291000002997019"
},
"subcategory": {
"name": "Hard FM",
"id": "4291000002997021"
},
"generated_events": [],
"status": {
"in_progress": true,
"internal_name": "Open",
"stop_timer": false,
"color": "#0066ff",
"name": "Open",
"id": "4291000000006657"
}
}
}
Edit Request Maintenance
This operation helps to edit a Request Maintenance
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}
Attributes
id (long)
Id of this maintenance
subject (string)
Subject of this maintenance[Max-length : 250]
description (html)
Description of this maintenance
impact_details (string)
Description about the impact of this maintenance[Max-length : 250]
email_ids_to_notify (string)
Array of Email ids, which needs to be filled in request created through this maintenance
delete_pre_template_tasks (boolean)
Boolean value indicating whether the pre template tasks need to be deleted
More Attributes Expand all
configuration_items (configuration_item)
Configuration Items for which the maintenance has been raised
repetitive_schedule (calendar_repetitive_schedule)
Indicates the repetitive_schedule of the maintenance
resolution (JSONObject)
A solution for the maintenance, provided by the technician
show attribute
service_approvers (JSONObject)
The configured users will be added to the first stage of approval for the service maintenance. It can be added only by Requesters.
show attribute
total_cost (double)read only
Total Cost is the cumulative value of service cost and the cost of the individual resources selected
is_service (boolean)read only
Boolean value indicating whether this maintenance is a service maintenance or not
$ curl <service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}\
-X PUT\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"\
-d input_data='{
"request_maintenance": {
"subject": "Request Maintenance Subject Here - Edited",
"impact_details": "Impacts Business in many aspects- edited"
}
}'
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
input_data = {
"request_maintenance": {
"subject": "Request Maintenance Subject Here - Edited",
"impact_details": "Impacts Business in many aspects- edited"
}
};
params = {"input_data": input_data};
response = invokeurl
[
url: url
type: PUT
parameters: params
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}"
$headers = @{"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
$input_data = @'
{
"request_maintenance": {
"subject": "Request Maintenance Subject Here - Edited",
"impact_details": "Impacts Business in many aspects- edited"
}
}
'@
$data = @{ 'input_data' = $input_data}
$response = Invoke-RestMethod -Uri $url -Method put -Body $data -Headers $headers
$response
#Python version - 3.10
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
input_data = '''{
"request_maintenance": {
"subject": "Request Maintenance Subject Here - Edited",
"impact_details": "Impacts Business in many aspects- edited"
}
}'''
data = urlencode({"input_data":input_data}).encode()
httprequest = Request(url, headers=headers,data=data, method="PUT")
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": {
"status_code": 2000,
"status": "success"
},
"request_maintenance": {
"template": {
"id": "4291000000006655",
"name": "Default Request"
},
"attachments": [],
"request_type": null,
"subject": "Request Maintenance Subject Here - Edited",
"description": "Description goes here",
"next_schedule": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"title": "Request Maintenance Subject Here - Edited",
"resolution": {
"content": "<div class=\"personalize-wrapper\" style=\"font-family:"Zoho Puvi", Roboto, sans-serif; font-size:13px\"><div>Resolution for created Maintenance<br><\/div><\/div>"
},
"repetitive_schedule": {
"is_advanced": true,
"next_execution_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"ends_on": null,
"days_of_month": null,
"parent_entity": "request_maintenance",
"last_execution_time": null,
"is_first_day_of_month": false,
"frequency": "Weekly",
"days_of_week": [
3,
5
],
"weeks_of_month": null,
"start_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"last_updated_by": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"exclude_weekends": false,
"months_of_year": null,
"day_config_of_month": null,
"last_updated_time": null,
"skip_frequency": "0",
"end_after_occurrences": "7",
"id": "4291000004120008",
"status": "enabled"
},
"mode": {
"internal_name": "E-Mail",
"name": "E-Mail",
"id": "4291000000006665"
},
"is_service": false,
"assets": [
{
"site": {
"id": "4291000001327001"
},
"product": {
"id": "4291000003115016"
},
"product_type": {
"id": "4291000000005925"
},
"name": "a1",
"id": "4291000003115020"
}
],
"configuration_items": [],
"urgency": {
"name": "High",
"id": "4291000000007919"
},
"id": "4291000004120001",
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"group": null,
"requester": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"created_time": {
"display_value": "Mar 18, 2025 11:12 AM",
"value": "1742276532086"
},
"item": null,
"one_time_schedule": null,
"level": {
"name": "Tier 1",
"id": "4291000000006671"
},
"impact": {
"name": "Affects Business",
"id": "4291000000008033"
},
"module": {
"api_plural_name": "requests",
"name": "request",
"display_name_plural": "sdp.module.pluralname.request",
"id": "4291000000085038",
"display_name": "Request",
"category": "SYSTEM",
"icon_name": null
},
"sla": null,
"technician": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"id": "4291000001327001"
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"is_vip_user": false,
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"department": {
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"priority": null,
"created_by": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"udf_fields": {
"udf_ref9": null
},
"maintenancestate": 1,
"impact_details": "Impacts Business in many aspects- edited",
"category": {
"deleted": false,
"name": "Centenary Court Building Maintenance",
"id": "4291000002997019"
},
"subcategory": {
"name": "Hard FM",
"id": "4291000002997021"
},
"status": {
"in_progress": true,
"internal_name": "Open",
"stop_timer": false,
"color": "#0066ff",
"name": "Open",
"id": "4291000000006657"
}
}
}
Get Request Maintenance
This operation helps to get a single request maintenance
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}
Attributes
id (long)
Id of this maintenance
subject (string)
Subject of this maintenance[Max-length : 250]
description (html)
Description of this maintenance
impact_details (string)
Description about the impact of this maintenance[Max-length : 250]
email_ids_to_notify (string)
Array of Email ids, which needs to be filled in request created through this maintenance
delete_pre_template_tasks (boolean)
Boolean value indicating whether the pre template tasks need to be deleted
More Attributes Expand all
configuration_items (configuration_item)
Configuration Items for which the maintenance has been raised
repetitive_schedule (calendar_repetitive_schedule)
Indicates the repetitive_schedule of the maintenance
resolution (JSONObject)
A solution for the maintenance, provided by the technician
show attribute
service_approvers (JSONObject)
The configured users will be added to the first stage of approval for the service maintenance. It can be added only by Requesters.
show attribute
total_cost (double)read only
Total Cost is the cumulative value of service cost and the cost of the individual resources selected
is_service (boolean)read only
Boolean value indicating whether this maintenance is a service maintenance or not
$ curl -G <service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}\
-X GET\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
response = invokeurl
[
url: url
type: GET
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$response = Invoke-RestMethod -Uri $url -Method get -Headers $headers
$response
#Python version - 3.8
#This script requires requests module installed in python.
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
httprequest = Request(url, headers=headers)
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": {
"status_code": 2000,
"status": "success"
},
"request_maintenance": {
"template": {
"id": "4291000000006655",
"name": "Default Request"
},
"attachments": [],
"request_type": null,
"subject": "Request Maintenance Subject Here",
"description": "Description goes here",
"next_schedule": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"title": "Request Maintenance Subject Here",
"resolution": {
"content": "<div class=\"personalize-wrapper\" style=\"font-family:"Zoho Puvi", Roboto, sans-serif; font-size:13px\"><div>Resolution for created Maintenance<br><\/div><\/div>"
},
"repetitive_schedule": {
"is_advanced": true,
"next_execution_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"ends_on": null,
"days_of_month": null,
"parent_entity": "request_maintenance",
"last_execution_time": null,
"is_first_day_of_month": false,
"frequency": "Weekly",
"days_of_week": [
3,
5
],
"weeks_of_month": null,
"start_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"last_updated_by": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"exclude_weekends": false,
"months_of_year": null,
"day_config_of_month": null,
"last_updated_time": null,
"skip_frequency": "0",
"end_after_occurrences": "7",
"id": "4291000004120008",
"status": "enabled"
},
"mode": {
"internal_name": "E-Mail",
"name": "E-Mail",
"id": "4291000000006665"
},
"is_service": false,
"assets": [
{
"site": {
"id": "4291000001327001"
},
"product": {
"id": "4291000003115016"
},
"product_type": {
"id": "4291000000005925"
},
"name": "a1",
"id": "4291000003115020"
}
],
"configuration_items": [],
"urgency": {
"name": "High",
"id": "4291000000007919"
},
"maintenance_end": "After 7 Occurrences",
"id": "4291000004120001",
"request_template_task_ids": [
{
"id": "4291000001479001"
}
],
"events": [
{
"end_date": "2025-04-09 12:00",
"event_length": "1",
"rec_type": "week_1___2,4#7",
"module": "request_maintenance",
"is_created": false,
"start_longvalue": "1742279400000",
"maintenance": "4291000004120001",
"start_date": "2025-03-18 12:00"
}
],
"group": null,
"requester": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"created_time": {
"display_value": "Mar 18, 2025 11:12 AM",
"value": "1742276532086"
},
"item": null,
"one_time_schedule": null,
"level": {
"name": "Tier 1",
"id": "4291000000006671"
},
"schedule_frequency": "Weekly",
"impact": {
"name": "Affects Business",
"id": "4291000000008033"
},
"module": {
"api_plural_name": "requests",
"name": "request",
"display_name_plural": "sdp.module.pluralname.request",
"id": "4291000000085038",
"display_name": "Request",
"category": "SYSTEM",
"icon_name": null
},
"sla": null,
"technician": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"id": "4291000001327001"
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"is_vip_user": false,
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"department": {
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"priority": {
"color": "#ff0000",
"name": "High",
"id": "4291000000006805"
},
"created_by": {
"email_id": "testuser@domain.com",
"is_technician": true,
"sms_mail": null,
"mobile": null,
"last_name": null,
"user_scope": "internal_user",
"sms_mail_id": null,
"cost_per_hour": "0",
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"phone": null,
"employee_id": null,
"name": "test",
"id": "4291000000145236",
"photo_url": "https://contacts.zoho.com/file?exp=10&ID=63184126&t=user&height=60&width=60",
"is_vip_user": false,
"department": {
"site": {
"id": "4291000001327001"
},
"name": "Engineering",
"id": "4291000000006625"
},
"first_name": "testuser",
"job_title": null
},
"site": {
"deleted": false,
"name": "Base Site",
"id": "4291000001327001",
"is_default": true
},
"udf_fields": {
"udf_ref9": null
},
"repeat_details": "Every 1 week on Tue, Thu ",
"maintenancestate": 1,
"impact_details": "Impacts Business in many aspects",
"category": {
"deleted": false,
"name": "Centenary Court Building Maintenance",
"id": "4291000002997019"
},
"subcategory": {
"name": "Hard FM",
"id": "4291000002997021"
},
"generated_events": [],
"status": {
"in_progress": true,
"internal_name": "Open",
"stop_timer": false,
"color": "#0066ff",
"name": "Open",
"id": "4291000000006657"
}
}
}
Get List Request Maintenance
This operation helps to get the list of all Request Maintenances
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances
Attributes
id (long)
Id of this maintenance
subject (string)
Subject of this maintenance[Max-length : 250]
description (html)
Description of this maintenance
created_time (datetime)
Indicates the time at which this maintenance is created
requester (user)
Technician assigned to this maintenance
customer (customer)
Denotes the customer to which this request belongs
More Attributes Expand all
repetitive_schedule (calendar_repetitive_schedule)
Indicates the repetitive_schedule of the maintenance
total_cost (double)read only
Total Cost is the cumulative value of service cost and the cost of the individual resources selected
is_service (boolean)read only
Boolean value indicating whether this maintenance is a service maintenance or not
$ curl -G <service domain|custom domain>/app/<portal>/api/v3/request_maintenances\
-X GET\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"\
--data-urlencode input_data='{}'
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
input_data = {};
params = {"input_data":input_data};
response = invokeurl
[
url: url
type: GET
parameters:params
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$input_data = @'{}'@
$data = @{ 'input_data' = $input_data}
$response = Invoke-RestMethod -Uri $url -Method get -Body $data -Headers $headers
$response
#Python version - 3.8
#This script requires requests module installed in python.
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
input_data = '''{}'''
url += "?" + urlencode({"input_data":input_data})
httprequest = Request(url, headers=headers)
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": [
{
"status_code": 2000,
"status": "success"
}
],
"request_maintenances": [
{
"created_time": {
"display_value": "Mar 18, 2025 11:12 AM",
"value": "1742276532086"
},
"one_time_schedule": null,
"subject": "Request Maintenance Subject Here",
"schedule_frequency": "Weekly",
"description": "Description goes here",
"next_schedule": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"repetitive_schedule": {
"is_advanced": true,
"ends_on": null,
"days_of_month": null,
"last_execution_time": null,
"is_first_day_of_month": false,
"frequency": "Weekly",
"days_of_week": [
3,
5
],
"weeks_of_month": null,
"start_time": {
"display_value": "Mar 18, 2025 12:00 PM",
"value": "1742279400000"
},
"exclude_weekends": false,
"months_of_year": null,
"day_config_of_month": null,
"skip_frequency": 0,
"end_after_occurrences": 7,
"id": "4291000004120008"
},
"is_service": false,
"repeat_details": "Every 1 week on Tue, Thu ",
"maintenancestate": 1,
"maintenance_end": "After 7 Occurrences",
"id": "4291000004120001",
"category": {
"deleted": false,
"name": "Centenary Court Building Maintenance",
"id": "4291000002997019"
}
},
{
"created_time": {
"display_value": "Feb 21, 2025 04:45 PM",
"value": "1740136517341"
},
"one_time_schedule": null,
"subject": "Please provide me an account in our CRM system",
"schedule_frequency": "Daily",
"description": "Please provide me an account in our CRM system",
"next_schedule": {
"display_value": "Mar 18, 2025 05:00 PM",
"value": "1742297400000"
},
"repetitive_schedule": {
"is_advanced": true,
"ends_on": null,
"days_of_month": null,
"last_execution_time": {
"display_value": "Mar 17, 2025 05:00 PM",
"value": "1742211020435"
},
"is_first_day_of_month": false,
"frequency": "Daily",
"days_of_week": null,
"weeks_of_month": null,
"start_time": {
"display_value": "Feb 21, 2025 05:00 PM",
"value": "1740137400000"
},
"exclude_weekends": false,
"months_of_year": null,
"day_config_of_month": null,
"skip_frequency": 0,
"end_after_occurrences": null,
"id": "4291000003927029"
},
"is_service": true,
"repeat_details": "Every 1 day",
"maintenancestate": 1,
"maintenance_end": "Never",
"id": "4291000003927025",
"category": null
}
],
"list_info": {
"has_more_rows": false,
"sort_field": "id",
"row_count": 4
}
}
Delete Request Maintenance
This operation allows to delete a Request Maintenance
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}
$ curl <service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}\
-X DELETE\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
response = invokeurl
[
url: url
type: DELETE
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$response = Invoke-RestMethod -Uri $url -Method delete -Headers $headers
$response
#Python version - 3.10
from urllib.error import HTTPError
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
httprequest = Request(url, headers=headers,method="DELETE")
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": {
"status_code": 2000,
"status": "success"
}
}
Enable
This operation allows to enable a Request Maintenance
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_enable
$ curl <service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_enable\
-X PUT\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"\
-d input_data='{
"comments": "Comments while enabling"
}'
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_enable";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
input_data = {
"comments": "Comments while enabling"
};
params = {"input_data": input_data};
response = invokeurl
[
url: url
type: PUT
parameters: params
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_enable"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$input_data = @'
{
"comments": "Comments while enabling"
}
'@
$data = @{ 'input_data' = $input_data}
$response = Invoke-RestMethod -Uri $url -Method put -Body $data -Headers $headers
$response
#Python version - 3.10
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_enable"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
input_data = '''{
"comments": "Comments while enabling"
}'''
data = urlencode({"input_data":input_data}).encode()
httprequest = Request(url, headers=headers,data=data, method="PUT")
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": {
"status_code": 2000,
"status": "success"
},
"enable": {
"id": "4291000004120001",
"message": "Maintenance enabled successfully"
}
}
Execute Now
This operation allows to instantly create a Request from Maintenance
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_execute_now
$ curl -G <service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_execute_now\
-X GET\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_execute_now";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
response = invokeurl
[
url: url
type: GET
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_execute_now"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$response = Invoke-RestMethod -Uri $url -Method get -Headers $headers
$response
#Python version - 3.8
#This script requires requests module installed in python.
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_execute_now"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
httprequest = Request(url, headers=headers)
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"response_status": {
"status_code": 2000,
"status": "success"
},
"maintenance": {
"display_id": "1",
"message": "New request created"
}
}
Suspend
This operation allows to suspend a Request Maintenance
Url
<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_suspend
$ curl <service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_suspend\
-X PUT\
-H "Accept: application/vnd.manageengine.sdp.v3+json"\
-H "Authorization: Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"\
-H "Content-Type: application/x-www-form-urlencoded"\
-d input_data='{
"comments": "Comments here"
}'
// Deluge Sample script
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_suspend";
headers = {"Accept":"application/vnd.manageengine.sdp.v3+json",
"Content-Type": "application/x-www-form-urlencoded",
"Authorization": "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"};
input_data = {
"comments": "Comments here"
};
params = {"input_data": input_data};
response = invokeurl
[
url: url
type: PUT
parameters: params
headers: headers
];
info response;
#Powershell version - 5.1
$url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_suspend"
$headers = @{ "Accept" = "application/vnd.manageengine.sdp.v3+json"
"Authorization" = "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx"
"Content-Type" = "application/x-www-form-urlencoded"}
$input_data = @'
{
"comments": "Comments here"
}
'@
$data = @{ 'input_data' = $input_data}
$response = Invoke-RestMethod -Uri $url -Method put -Body $data -Headers $headers
$response
#Python version - 3.10
from urllib.error import HTTPError
from urllib.parse import urlencode
from urllib.request import urlopen,Request
url = "<service domain|custom domain>/app/<portal>/api/v3/request_maintenances/{request_maintenance_id}/_suspend"
headers ={"Accept": "application/vnd.manageengine.sdp.v3+json",
"Authorization" : "Zoho-oauthtoken 1000.7xxx98976ab0xxxxxx19901e7551be57.bxxxx921ed64c04f79622bebcfxxxxxx",
"Content-Type" : "application/x-www-form-urlencoded"}
input_data = '''{
"comments": "Comments here"
}'''
data = urlencode({"input_data":input_data}).encode()
httprequest = Request(url, headers=headers,data=data, method="PUT")
try:
with urlopen(httprequest) as response:
print(response.read().decode())
except HTTPError as e:
print(e.read().decode())
{
"suspend": {
"id": "4291000004120001",
"message": "Maintenance suspended successfully"
},
"response_status": {
"status_code": 2000,
"status": "success"
}
}