Enqueueing a downlink via v4 REST API

I have a v4 server setup with the optional Python REST API added to it - using the standard port 8090.

I am attempting to send a simple hex payload to one of my devices.

I am using this API:

8090/#/DeviceService/DeviceService_Enqueue

I am inputing the correct API key and DevEUI - the problem is I’m not sure what the “Body” in the POST should contain.

I have been trying:

{
“queueItem”: {
“confirmed”: true,
“data”: “30303030”,
“fCntDown”: 0,
“fPort”: 0,
“id”: “string”,
“isPending”: true,
“object”: {}
}
}

I have also tried 30303030 in base64, the plain simple string: “0000”

I am attempting to send the string “0000”

When I manually enqueue a downlink from the server’s UI entry for the device using the “hex” option, it shows the downlink in the queue with “30303030” as the hex data - as expected.

Whenever I enqueue something via the Python REST API - it always show null in that portion of the queued entry when viewed on the server.

fPort=0 is incorrect. It should be for MAC commands only.
fPort shoud be any positive number except 0.
data is base64.

{
“queueItem”: {
“confirmed”: true,
“data”: “AwER”,
“fPort”: 2
}
}

Thank you - this worked.
I was going by the template provided when clicking on this end point in the REST API.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.