Push Notification Template using message helpers

0

I'm creating a push notification template and would like to use the message helpers to control the messages depending on the custom attributes that I use, by following this documentation https://docs.aws.amazon.com/pinpoint/latest/userguide/message-template-helpers.html. But unfortunately I'm getting this kind of error.Error occurs when sending the push notification on test messaging in pinpoint

this is my current push notification template and just adding the helper on my message attributes, by just checking if the numbers are equal then they return the specified string messages.

"GCMMessage": {
    "notification": {
      "title": "サンプルメッセージ送信 タイトル",
      "body": "Welcome to AWS"
    },
    "data": {
      "message": "{{#eq 1111 11211}} Your City is on Alert Level 1! {{else}} Your City is on Alert Level 2! {{/eq}}"
    }
  },

I tried the message helpers also on creating Emails and its a success. So I'm wondering what's wrong. Is the syntax for push notification template(JSON) different when using the message helpers? Because I see no alternative syntax written on the documentation for push templates, so I'm assuming its just the same for the other templates. Can anyone provide any guides or resource that I can look with? Thank in advance.

asked 2 years ago87 views
No Answers

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions