在一个信号推送通知中出错:内容必须是 key/value 语言代码的集合
Getting an error in one signal push notification : contents must be key/value collections by language code
我正在尝试将简单消息设置为一个信号请求正文中的内容字段。我收到一条错误消息 "contents must be key/value collections by language code".
ObjectNode jsonMessage = Json.newObject();
jsonMessage.put("contents", "{\"en\": \"English Message\"");
Push Response******** {"errors":["contents must be key/value collections by language code"]}
确保 JSON 字符串的格式正确,例如:
{"en": "English Message", "es": "Spanish Message"}
我正在尝试将简单消息设置为一个信号请求正文中的内容字段。我收到一条错误消息 "contents must be key/value collections by language code".
ObjectNode jsonMessage = Json.newObject();
jsonMessage.put("contents", "{\"en\": \"English Message\"");
Push Response******** {"errors":["contents must be key/value collections by language code"]}
确保 JSON 字符串的格式正确,例如:
{"en": "English Message", "es": "Spanish Message"}