webApp luna-send response : "Denied method"

Hi, I am new to webOS development.

I have a raspberry pi 3B, loaded with webOS.
I have created a webapp, to test the luna-send command.
When my webapp send a command :
webOS.service.request(luna://com.webos.service.systemservice/deviceInfo/query).
The return response is :
{returnValue:false, errorCode : 01, errorText: "Denied method call query for category deviceInfo""}

If I SSH to the raspberry, I am able to execute the same command without error.

My question is : how can I make the webApp to send a webOS.service.request command successfully?

Hi peow,

Your web app can't call this method directly. If you want to call this method in your app, you should make internal system service or JS Service component to relay that method.

deviceInfo/query
Description

The query method to get the device system information such as product Id, system number, hardware information, Wi-FI address, battery status and others. Please refer to the return values table below for a complete list of the system parameters.

Note: This is an internal method. Third-party applications cannot use it.

Can you advise which application can be used?

QML?
Enact?
Native?

What about the bluetooth2 service?

webOS.service.request(luna://com.webos.service.bluetooth2/adapter/queryAvailable

gives the "Denied method" as well.