• Simple Message Notification

smn
  1. Help Center
  2. Simple Message Notification
  3. API Reference
  4. APIs
  5. Template Operation
  6. Querying the Message Template Details

Querying the Message Template Details

Description

  • API name

    QueryMessageTemplateDetail

  • Function

    Query the template details, including the template content.

URI

  • URI format

    GET /v2/{project_id}/notifications/message_template/{message_template_id}

  • Parameter description

    Parameter

    Mandatory

    Type

    Description

    project_id

    Yes

    String

    Project ID

    message_template_id

    Yes

    String

    Resource identifier of the template, which is unique

Request

Request example
GET /v2/{project_id}/notifications/message_template/57ba8dcecda844878c5dd5815b65d10f

Response

  • Parameter description

    Parameter

    Type

    Description

    message_template_id

    String

    Template ID

    message_template_name

    String

    Template name

    protocol

    String

    Protocol supported by the template

    NOTE:

    Currently, email, sms, dms, http, and https are supported.

    tag_names

    String

    Template tag list

    create_time

    String

    Time when the template was created

    The value is a UTC time.

    update_time

    String

    Last time when the template was updated

    The value is a UTC time.

    content

    String

    Template content

    request_id

    String

    Request ID, which is unique

  • Response example
    {
        "message_template_name": "confirm_message",
        "protocol": "https",
        "update_time": "2016-08-02T08:22:25Z",
        "create_time": "2016-08-02T08:22:20Z",
        "request_id":"ba79ca8f794f4f50985ce7b98a401b47",
        "tag_names": [
            "topic_id_id4"
        ],
        "content": "(1/24)You are invited to subscribe to topic({topic_id_id4}). Click the following URL to confirm subscription:(If you do not want to subscribe to this topic, ignore this message.)",
        "message_template_id": "57ba8dcecda844878c5dd5815b65d10f"
    }

Returned Value

See section Returned Value.

Error Code

See section Error Code.