Aws iot-rule-protobuf

0

Hi i am trying to test protobuf capability of aws-iot rule. i have configured everything But i am stuck at payload type. So lets say i have protbuf encoded bytes as follow:

payload="\n3\ræ\x87EA\x15\x03O¯B\x1d\x00\x00\x00\x00%\x00\x00ÈB(\x001\x00\x00\x00\x00\x00\x00\x00\x008\x00E\x00\x00\x00\x00H\x00U\x00\x00\x00\x00X\x00`\x00h\x00"

(NOTE: 'payload=' is not being sent. I wrote here just to show that this is the payload)

And when i am trying to publish this bytes as it is then configured protobuf iot-rule is throwing error with reason "JsonParseError".

  1. So is my payload correct?
  2. What exacty is binary payload or its format in aws (an example would be good)?
已提問 6 個月前檢視次數 143 次
2 個答案
0
AWS
Luca V
已回答 6 個月前
0

Hi Thanks for sharing the blogs. They are useful. I'm still unable to work with binary payload. But i have implemented using base64 string in json payload:

{
"a":"base64string"
}

This works.

已回答 6 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南