Skip to main content
Platform O&M/Cloud Monitoring/Monitoring and Alarm/SNS/ZWatch Operations/Text Template Operations
PUTText Template OperationsSince 3.7.0SynchronousAuth Required

UpdateAliyunSmsSNSTextTemplate

UpdateAliyunSmsSNSTextTemplate

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Path Parameters

Request Inputs

Path Parameters

  • uuidStringRequired

    The template UUID.

Body Fields

  • updatealiyunsmssnstexttemplateObjectRequired

    updatealiyunsmssnstexttemplate request body object.

    • alarmTemplateCodeString

      Optional. The resource alarm template code.

    • signString

      Optional. The SMS message signature.

    • eventTemplateCodeString

      Optional. The event template code.

    • eventTemplateString

      Optional. The event alarm template text.

    • nameString

      Optional. The template name.

    • descriptionString

      Optional. The detailed description of the template.

    • templateString

      Optional. The resource alarm template text.

    • recoveryTemplateString

      Optional. The recovery template text.

    • defaultTemplateBoolean

      Optional. Whether to set the template as the default template.

  • systemTagsList

    Optional. The system tags.

  • userTagsList

    Optional. The user tags.

Responses

200 OK

On success, this API returns the following response structure.

  • errorErrorCodeRequired

    The error code. If not null, the operation fails, or vice versa. For more information, see error.

    • codeStringRequired

      The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001.

    • descriptionStringRequired

      The brief description of the error.

    • detailsStringRequired

      The details about the error.

    • elaborationStringRequired

      The reserved field. Default value: null.

    • opaqueLinkedHashMapRequired

      The reserved field. Default value: null.

    • causeErrorCodeRequired

      The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null.

  • inventoryAliyunSmsSNSTextTemplateInventoryRequired

    See inventory.

    • alarmTemplateCodeStringRequired

      The resource alarm template code.

    • signStringRequired

      The SMS message signature.

    • eventTemplateCodeStringRequired

      The event alarm template code.

    • eventTemplateStringRequired

      The event alarm template text.

    • uuidStringRequired

      The template UUID.

    • nameStringRequired

      The template name.

    • descriptionStringRequired

      The detailed description of the template.

    • applicationPlatformTypeStringRequired

      The application platform type.

    • templateStringRequired

      The resource alarm template text.

    • recoveryTemplateStringRequired

      The recovery template text.

    • defaultTemplateBooleanRequired

      Whether to set the template as the default template.

    • createDateTimestampRequired

      The creation date.

    • lastOpDateTimestampRequired

      The last operation date.

Endpoint

PUT/zstack/v1/zwatch/alarms/sns/text-templates/{uuid}/actions

/zstack/v1/zwatch/alarms/sns/text-templates/{uuid}/actions

Operation ID

UpdateAliyunSmsSNSTextTemplate

Permalink

Request Example

curl -X PUT 'http://{host}/zstack/v1/zwatch/alarms/sns/text-templates/{uuid}/actions' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"updatealiyunsmssnstexttemplate":{"alarmTemplateCode":"<alarmTemplateCode>","sign":"<sign>","eventTemplateCode":"<eventTemplateCode>","eventTemplate":"<eventTemplate>","name":"<name>","description":"<description>","template":"<template>","recoveryTemplate":"<recoveryTemplate>","defaultTemplate":true},"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'

Response Example

200
{ "inventory": { "alarmTemplateCode": "SMS_153055065", "sign": " Sample signature", "eventTemplateCode": "SMS_123456789", "eventTemplate": "Event ${EVENT_NAME} had just happened", "uuid": "f8b819b8af9c402fac43932ef95cb468", "name": "email template", "applicationPlatformType": "AliyunSms", "template": "Alarm ${ALARM_NAME} changes status to ${ALARM_CURRENT_STATUS}", "recoveryTemplate": "Resource ${EVENT_RESOURCE_ID} changes status to ${ALARM_CURRENT_STATUS}", "defaultTemplate": false, "createDate": "Oct 8, 2019 5:32:12 PM", "lastOpDate": "Oct 8, 2019 5:32:12 PM" } }

Change History

This API has no change history records yet.

View all change history