# Create a Maintenance Template Creates a new template. Template don't have to contain values set for all possible fields. If there is no value present for one of the field, during applying the template such field will be ignored. Endpoint: POST /hubs/{subdomain}/maintenance_templates Version: 3.0-R1 Security: ApiKeyAuth ## Path parameters: - `subdomain` (string, required) Unique subdomain of requested Hub. ## Query parameters: - `api_version` (string) Api version Enum: "V3-R1" ## Request fields (application/json): - `title` (string,null) Title of event. Can be omitted if body is provided. Can contain only plain text. HTML tags and other forms of formatting are not allowed. Templates without title set will ignore event title when applied. - `body` (string,null) Title of event. Can be omitted if title is provided. Can contain basic HTML tags and is being interpreted as HTML. Templates without body set will ignore event body when applied. - `duration` (integer,null) Duration of maintenance in minutes. Maximum allowed value is 99h:59min (5999 minutes). - `labels` (array) List of labels for this template. Template can have many labels. If passing just one label, it should still be passed as an array: "labels": ["some label value"]. - `service_statuses` (array) Describes affected services and their statuses. - `service_statuses.service_id` (integer) Example: 1234 - `service_statuses.status` (string) Enum: "up", "degraded-performance", "down" - `silent` (boolean,null) Controls silent parameter value when applying the template: * true - Set event silent parameter as true, * false - Set event silent parameter as false, * null - Do not set event silent parameter. ## Response 200 fields (application/json): - `id` (integer) Example: 60 - `title` (string,null) Title of event. Templates without title set will ignore event title when applied. - `labels` (array) List of labels for this template. - `flags` (object) - `flags.deleted` (boolean) Is this template deleted. Deleted templates can't be used when creating or updating events. - `flags.silent` (boolean,null) Controls silent parameter value when applying the template: * true - Set event silent parameter as true, * false - Set event silent parameter as false, * null - Do not set event silent parameter. - `duration` (integer,null) Duration of maintenance in minutes. - `body` (string,null) Title of event. Templates without body set will ignore event body when applied. - `created_at` (string) Timestamp of record creation. ISO8601 formatted time (UTC). Example: "2020-09-01T08:29:00Z" - `updated_at` (string) Timestamp of last modification of record. ISO8601 formatted time (UTC). Example: "2020-09-01T08:29:00Z" - `author` (string,null) Author email - `service_statuses` (array) - `service_statuses.service_id` (integer) Example: 62 - `service_statuses.service_name` (string) - `service_statuses.status` (string) Enum: "up", "degraded-performance", "down" - `service_statuses.group_id` (integer) Example: 63 - `service_statuses.group_name` (string)