Webhook pending and payload formatter

Hello, I am new into setting LoRa sensors. I have created device gateway and managed to connect the sensors. I want to use ThingSpeak to record the data and do analysis.
Screen Shot 2021-12-23 at 2.40.11 pm
Screen Shot 2021-12-23 at 2.31.49 pm
First issue: I have webhook pending? Have miss a step?
Second question: Payload formatter: I am planning to use the following javascript:
function Decoder(b,port)(input){
var mytime = ((bytes[3] << 24) | (bytes[2] << 16) | (bytes[1] << 8) | bytes[0] );
var Temp = ((bytes[5] << 8) | bytes[4];
var Humi = ((bytes[7] << 8) | bytes[6];
Not sure if I have the bytes correct. Thank you for your help.
Tosin
Screen Shot 2021-12-23 at 2.40.11 pm
I just look at the detail event it shows the following error:
@type": “type.googleapis.com/google.protobuf.Struct”,
“value”: {
“body”: “{“success”:false,“error”:{“message”:“Alias uplinks not found”,“id”:null}}”,
“status_code”: 404,
“url”: “https://webhook.site/uplinks”,
“webhook_id”: “XXXXwebhook”

Screen Shot 2022-01-29 at 7.42.15 am
Hello Everyone,
I am not sure why the webhook gives me pending.
First, I tried to connect to Thingspeak. I have the webhook pending.
Secondly, I tried to connect to Cayenne same, error, webhook pending.
Could this because I am on the free plan? Is the webhook available to all. I have followed the documentation but does not understand webhook is pending.
Thanks all for reading and helping with this.
Regards,
Tosin

Regardless of the status, does it work?

Try a forum search for more info about pending status

Thank you @descartes I have checked the pending status forum. My problem seems to persist. I have added a / to base url and checked the Enable and remove all link.
I appreciate your comment.
T_Redacted.pdf (106.2 KB)

If this were true, you’d have read that it is still work in progress and not implemented.

Because?

And did you check to see if data was arriving as suggested? Or are you trying to remove a message that can’t be removed at present? If data is arriving, then there is nothing for you to do. You may need to revisit the original instructions so any alterations you’ve made are reset so the setup is compromised with debugging the un-debuggable.

Does it?

Nick asked

Does data arrive at your end application/dashboard of choice?
I just checked a bunch of my devices and applications before posting this - units from e.g. Dragino, Laird, RAK etc. firing off webhook integrations to the likes of Cayenne & TTN Mapper…the data arrives just fine - always has…
…but webhook status still says pending! Its not in place yet per search results…

Thanks @Jeff-UK The data is not arriving at the end application. That is Thingspeak is not receiving the data from TTN.
Webhook status still show pending.

If you keep telling us this, we’ll get bored and leave you to it. It’s not going to change. We are not support, we are volunteers.

Have you reset your integration so you can start from a clean sheet rather than the one you’ve been trying to make work?

Has zero relevance right now and is distracting/sidetracking you Ignore It.…you have other problems if your integration target isnt ‘receiving’ data…as Nick says go back to square one and start again - reset integration or even start with a fresh webhook…we have no way of knowing what you may have changes or upset that would stop things working as expected…

@Jeff-UK thank you so much. I have deleted the webhook and started again. I am just not sure what I am doing wrong from TTN side. I have now tried webhook integration to Datacake, Thingspeak and Cayenne. Following all the instruction from my end, all the webhook shows is that it is pending. Data is not sent from TTN to Datacake, Thingspeak and Cayenne.

Are you actually reading anything we type or is this some sort of subtle trolling?

Go and look again at what we’ve both said about the relevance of the pending message.

And then create a temporary end-point at https://webhook.site, use the provided URL to create a new custom webhook (scroll right to the bottom), watch your application console for an incoming uplink (we are presuming you do in fact have some devices running) and then see it arrive on the webhook.site.

The setup of the integration, which I’ve just tested (took 45 seconds to create & see it working), was using their button to copy the URL to the clipboard, create webhook, give it an id, paste in the URL and tick the uplink box. I categorically did not alter the URL in any way nor did I add any information in to the box to the right of the uplink enabled check box that I ticked. But I did press Save. And yes, mine showing pending as well, because that’s what we expect.

Just saw this so thought I would try - took 28 sec to set up from clicking link from forum post to test site, then had to wait about 2.5 mins for a dragino tracker in car on drive to send data - happily received device details, payload showing gps location receiving GW’s metadat etc just as expected… as Nick will attest if I can do it (IANASWE) … :scream_cat:

(Note the device and associated app were already running and happily been feeding data to Cayenne for last ~2years & TTN Mapper for ~1 year and has V2 to V3 migration around Sept/Oct last year so not a new set up but one that I knew ‘worked’…could also see decoded data arriving in Console view and now it shows on the test site)

Nick, :+1: for the test site tip :slight_smile:

1 Like

@Jeff-UK @descartes thank you both for your patience. I understand now that pending status is not the issue.
I have created a custom webhook with provided url. I can see the uplink to webhook is okay.
Screen Shot 2022-01-30 at 11.38.45 am

Could the problem then with my setup from webhook to Cayenne or ThingSpeak?

Show a screenshot of your cayenne webhook and we might be able to guide you in the right direction. With the current information all we can say is yes, there will be a problem somewhere in how you set things up as it is working for others.

CayenneWebhook.pdf (73.2 KB)
@kersing Thank you for your assistance. Here is the screen shot. I continue to see the data on using the custom webhook, but some how the data is not going to Cayenne or Datacake.

Again, are you reading what we are typing?

You have lots of extras in what is almost a one click setup - setup one with just the TTS Webhook Id. Start from a clean sheet - just delete what you’ve got and start over.

Others things to check:

  • Is your device sending in CayenneLPP format?
  • Have you copied over the Device EUI to Cayenne?

Can you tell us BOTH of these things:

  • What is the device - make, model, revision, firmware.
  • Can you provide the text formatted using the </> tool on this message entry box - PDF downloads are just clutter that we have to delete from our computers after - of the JSON of the device uplink please (find an uplink, click the line that says “Forward uplink data message”, displayed on the right).

FWIW, I don’t use Cayenne but I do have an account. I don’t use CayenneLPP but I have a TTN Generic Node that is setup for it, I’ve put in batteries, copied over the EUI to Cayenne, created a webhook with no extras and I can see data on the Cayenne console. Took about 5 minutes (3 finding the device). @Jeff-UK who knows it much better than me will have done it in 30 seconds.

@descartes thank you for the reply. I appreciate the time you all are taking to reply to my mail.

Is your device sending in CayenneLPP format?  Yes
Have you copied over the Device EUI to Cayenne? Yes

Current device: Netvox Lora Sensor R809A01, Hardware
Brand netvox Model r809a Hardware version 12 Firmware version 10
Belowis the Forward uplink data message. Using custom webhook page, I continue to see the data.

{
  "name": "as.up.data.forward",
  "time": "2022-01-30T13:16:58.449428048Z",
  "identifiers": [
    {
      "device_ids": {
        "device_id": "eui-00137a1000010633",
        "application_ids": {
          "application_id": "temperaturehumidity1"
        }
      }
    },
    {
      "device_ids": {
        "device_id": "eui-00137a1000010633",
        "application_ids": {
          "application_id": "temperaturehumidity1"
        },
        "dev_eui": "00137A1000010633",
        "join_eui": "00137A1000008128",
        "dev_addr": "260DA25B"
      }
    }
  ],
  "data": {
    "@type": "type.googleapis.com/ttn.lorawan.v3.ApplicationUp",
    "end_device_ids": {
      "device_id": "eui-00137a1000010633",
      "application_ids": {
        "application_id": "temperaturehumidity1"
      },
      "dev_eui": "00137A1000010633",
      "join_eui": "00137A1000008128",
      "dev_addr": "260DA25B"
    },
    "correlation_ids": [
      "as:up:01FTNJ3BPAR1AHEQBMRVA49V2R",
      "gs:conn:01FT7SXBTEH8NK4C0KAFX33TH1",
      "gs:up:host:01FT7SXC2M1B11XZKPZ65DMCPD",
      "gs:uplink:01FTNJ3BFQZ4J1PKDPPZPTXZKG",
      "ns:uplink:01FTNJ3BFTBDJT59CCVMN5ZMRN",
      "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01FTNJ3BFSCV8RT8QPBHCYKR41",
      "rpc:/ttn.lorawan.v3.NsAs/HandleUplink:01FTNJ3BPACBQ2FVGC6ZG8PHR1"
    ],
    "received_at": "2022-01-30T13:16:58.443282010Z",
    "uplink_message": {
      "session_key_id": "AX6qYRYLOeA0PLgzA8K/aA==",
      "f_port": 6,
      "f_cnt": 26,
      "frm_payload": "AQ4BAQAAABUAAAA=",
      "rx_metadata": [
        {
          "gateway_ids": {
            "gateway_id": "multitech-001",
            "eui": "00800000A0008C10"
          },
          "timestamp": 3561917612,
          "rssi": -59,
          "channel_rssi": -59,
          "snr": 10,
          "uplink_token": "ChsKGQoNbXVsdGl0ZWNoLTAwMRIIAIAAAKAAjBAQrJm6og0aCwjKn9qPBhCK/7duIOD/1ZbVr2Y=",
          "channel_index": 7
        }
      ],
      "settings": {
        "data_rate": {
          "lora": {
            "bandwidth": 125000,
            "spreading_factor": 7
          }
        },
        "coding_rate": "4/5",
        "frequency": "923000000",
        "timestamp": 3561917612
      },
      "received_at": "2022-01-30T13:16:58.234171549Z",
      "consumed_airtime": "0.061696s",
      "version_ids": {
        "brand_id": "netvox",
        "model_id": "r809a",
        "hardware_version": "12",
        "firmware_version": "10",
        "band_id": "AS_923"
      },
      "network_ids": {
        "net_id": "000013",
        "tenant_id": "ttn",
        "cluster_id": "ttn-au1"
      }
    }
  },
  "correlation_ids": [
    "as:up:01FTNJ3BPAR1AHEQBMRVA49V2R",
    "gs:conn:01FT7SXBTEH8NK4C0KAFX33TH1",
    "gs:up:host:01FT7SXC2M1B11XZKPZ65DMCPD",
    "gs:uplink:01FTNJ3BFQZ4J1PKDPPZPTXZKG",
    "ns:uplink:01FTNJ3BFTBDJT59CCVMN5ZMRN",
    "rpc:/ttn.lorawan.v3.GsNs/HandleUplink:01FTNJ3BFSCV8RT8QPBHCYKR41",
    "rpc:/ttn.lorawan.v3.NsAs/HandleUplink:01FTNJ3BPACBQ2FVGC6ZG8PHR1"
  ],
  "origin": "ip-10-102-4-106.ap-southeast-2.compute.internal",
  "context": {
    "tenant-id": "CgN0dG4="
  },
  "visibility": {
    "rights": [
      "RIGHT_APPLICATION_TRAFFIC_READ",
      "RIGHT_APPLICATION_TRAFFIC_READ"
    ]
  },
  "unique_id": "01FTNJ3BPHHH4PB4W9H2MM258E"

Your payload output is invalid.

If you turn on the CayenneLPP payload formatter it will help with debugging, and, double bonus, you can use it to test your payload format.

Maybe you haven’t told the Netvox it needs to send CayenneLPP (I wouldn’t know if it can or can’t or how to do that, my brain is too small to hold all the devices info).

1 Like

Is this your 1st device on LoRaWAN/TTN? Maybe not the easiest 1st start device - personally I would get up and running with a simple Class A device - say a T&H sensor - use then as a canary for your GW? The Netvox is a Class C device and whilst all Class C & Class B devices must also support Class A operation you will get best value from it as a Class C device. Problem then is if using on TTN for e.g. power control you need to be aware of TTN FUP for MAX 10 DL per day, and nominally 1 per week or per month to benefit the community :wink: So not for repeatidly turning devices on and off under remote control or in response to other sensor condition. It claims MyDevices/Cayenne support but have no direct experience of this and dont know if LPP enabled by default. A Nick suggests make sure you have CLPP enabled for your uplinks in TTN Console Payload formatter - you should then see decoded data in console as a 1st indicator of all good - if you dont get that far Cayenne Dashboard itself unlikely to help, if good on TTN then you can look at details of TTN/Cayenne exchange and Cayenne settings…

Job #1 - get a simple easy to use T&H for Class A, with know good/simple Cayenne setup/support, 1st - Dragino LHT65 or perhaps (ok, a bit more expensive and better utility/features/options) a Laird RS1xx and set that up so you know what a functional system should look like. If you want to stick with Netvox I know they have a broad range of quite well respected and often used sensors inc. T&H - the R711 if I recall - but as I have not had any units from them to test/eval or critique I have no direct experience to say if simple or overly complex to set up

BTW having mentioned T&H as 1st step I just looked back and notice your OP called out as temp & humidity data per the picture you posted (what device was that? (- Update - Ah ignore - just saw it is…a R711 - bingo!) - did you get that up and running in Cayenne? Also your post of the webhook test site capture calls out application ID as “temperaturehumidity1”

…and you are using that for a power controller?

Have you set up a different App for the R809? and registered the device in there and then set up webhook to Cayenne from that? …am giving up at this point! :wink: