NRF Cloud Message Routing Service not sending payload in device data message

Hi,

I have set up a destination in the the NRF Cloud Message Routing Service

The destination has been verified and I can successfully send the test message from NRF Cloud and receive the message and payload at the destination. All good there.

However, when my devices send data to NRF Cloud, NRF Cloud forwards the message to the configured destination without a payload. I can seen the message being received at the destination by no JSON.

Example of received test message and device data (empty)

When I send a simulated nrf cloud payload - As shown in the Message Routing Service documentation - the destination accepts the message without error.

NRF Clouds also shows there have been 0 message failures

How can I check what data is being sent to the destination? 

Is there any reason why empty payloads are being sent?

  • Hi,

    Can you elaborate what exactly is shown in your screenshot?
    Where was the screenshot taken from?
    Which scheme did you use?
    What is the type of the message batch (in payload fields) that you used when empty payload was received at the destination?

    Best regards,
    Dejan

  • Sure - The screenshot is the log of received http requests at the destination end. Effectively, these are the messages that have been sent by the nrf cloud message routing service.

    I am using the Cellular: nRF Cloud multi-service sample to send data from the device to the cloud. nrf cloud is communicating with the device perfectly.

    I am not sure what you mean by "type of the message batch (in payload fields)". The data being sent from the device to NRF cloud is as follows:

    "Received":{
    4 items
    appId:"HEARTBEAT"
    messageType:"DATA"
    ts:1746636363130
    data:1
    }

    "Received":{
    4 items
    appId:"BATTERY"
    messageType:"DATA"
    ts:1746636378131
    data:100
    }


    I assume the Message Routing service should be sending a payload like the following example:


    {
      "type": "device.messages",
      "timestamp": "2024-09-05T21:59:47.323Z",
      "messages": [
        {
          "teamId": "26fc871f-1272-45ef-9db2-0145a6b0dfcd",
          "deviceId": "nrf-278345628733",
          "messageId": "9b66d97e-9747-4690-a464-073748736603",
          "receivedAt": "2024-09-05T21:59:44.714Z",
          "topic": "dev/26fc871f-1272-45ef-9db2-0145a6b0dfcd/m/d/nrf-278345628733/d2c",
          "message": {
            "appId": "TEMP",
            "messageType": "DATA",
            "data": "14"
          }
        },
        {
          "teamId": "26fc871f-1272-45ef-9db2-0145a6b0dfcd",
          "deviceId": "nrf-278345628733",
          "messageId": "23f5bbc1-2dd8-455e-962a-cad780d469f9",
          "receivedAt": "2024-09-05T21:59:45.306Z",
          "topic": "dev/26fc871f-1272-45ef-9db2-0145a6b0dfcd/m/d/nrf-278345628733/d2c",
          "message": {
            "appId": "GPS",
            "messageType": "DATA",
            "data": "$GPGGA,195032.465,4531.255,N,12240.318,W,1,12,1.0,0.0,M,0.0,M,,*79"
          }
        }
      ]
    }

  • Just wondering if you can provide any further information as to why device messages are not being forwarded by the Message Routing Service?

  • Hi Clinto,

    Before we continue troubleshooting, please confirm from the message store if you can see the message and the content. Are they empty as well?

    API, for reference:

    https://api.nrfcloud.com/v1/#tag/Messages/operation/ListMessages

    Or check from the portal (Device management -> Devices).  Choose your device and then you can watch messages as they are delivered to nRF Cloud. Do you see the content there?

    Best regards,

    Markku Lehto

  • Thank you for the guidance.

    I have confirmed by both methods you described, that messages with data is being received by nrf cloud.

    Using the HTTP API I can see a long list of messages with data that have the correct data and also in the portal.

    It just never gets passed on the the Message Routing Service for some reason.

Related