cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

[SOLVED] User does not have visibility permission for ContentLoaderFunctions

Hannes
4-Participant

[SOLVED] User does not have visibility permission for ContentLoaderFunctions

Hello everyone,

 

i created a thing with a subscription in it. The subscription is configured with the Event DataChange and it is thrown.

The Problem is, that in the script of the description in want to make a RESTFul API call with GET.

I have the following code into the script:

 

 

var params = {
	proxyScheme: undefined /* STRING */,
	headers: undefined /* JSON */,
	ignoreSSLErrors: true /* BOOLEAN */,
	useNTLM: false /* BOOLEAN */,
	workstation: undefined /* STRING */,
	useProxy: false /* BOOLEAN */,
	withCookies: undefined /* BOOLEAN */,
	proxyHost: undefined /* STRING */,
	url: 'http://localhost:5000' /* STRING */,
	timeout: undefined /* NUMBER */,
	appendHeader: undefined /* BOOLEAN */,
	proxyPort: undefined /* INTEGER */,
	password: undefined /* STRING */,
	domain: undefined /* STRING */,
	username: undefined /* STRING */
};

// result: JSON
var result = Resources["ContentLoaderFunctions"].GetJSON(params);
logger.warn(result);
logger.warn(result.W1);
logger.warn(me.ktid.ktid);

me.coolerValue1 = result.W1 + "/" + result.W2 + "/" + result.W3;

 

 

When the event is thrown i got the following error message in the logs:

 

 

User does not have visibility permission for ContentLoaderFunctions

AND (anonymous)

Execution error in service script [<THINGNAME>Event.DataChange:Property.ktid] : Wrapped java.lang.RuntimeException: Entity [ContentLoaderFunctions] does not exist Cause: Entity [ContentLoaderFunctions] does not exist

What permissions are left here?

 

Thanks in advance

Hannes

 

ACCEPTED SOLUTION

Accepted Solutions

Add visibility and runtime permission to "Resources" to the user/organization on "SYSTEM" category. This may be the issue. 

View solution in original post

3 REPLIES 3

Add visibility and runtime permission to "Resources" to the user/organization on "SYSTEM" category. This may be the issue. 

Hannes
4-Participant
(To:Sathishkumar_C)

Hey, thanks for the fast response. Thats it! It worked when i added visbility and runtime permissions to the resource "ContentLoaderFunctions".

 

Thanks a lot!

Cool.
Announcements


Top Tags