401 auth req when get all user data

17 views
Skip to first unread message

mohammad hanifah nur shafrudin

unread,
Oct 13, 2017, 6:51:08 AM10/13/17
to LoopbackJS
i always get response 
{ "error": { "statusCode": 401, "name": "Error", "message": "Authorization Required", "code": "AUTHORIZATION_REQUIRED", "stack": "Error: Authorization Required\n at C:\\Project_Node\\Learnapp\\node_modules\\loopback\\lib\\application.js:392:21\n at C:\\Project_Node\\Learnapp\\node_modules\\loopback\\lib\\model.js:358:7\n at C:\\Project_Node\\Learnapp\\node_modules\\loopback\\common\\models\\acl.js:529:16\n at C:\\Project_Node\\Learnapp\\node_modules\\async\\dist\\async.js:3861:9\n at C:\\Project_Node\\Learnapp\\node_modules\\async\\dist\\async.js:421:16\n at iteratorCallback (C:\\Project_Node\\Learnapp\\node_modules\\async\\dist\\async.js:998:13)\n at C:\\Project_Node\\Learnapp\\node_modules\\async\\dist\\async.js:906:16\n at C:\\Project_Node\\Learnapp\\node_modules\\async\\dist\\async.js:3858:13\n at C:\\Project_Node\\Learnapp\\node_modules\\loopback\\common\\models\\acl.js:511:17\n at C:\\Project_Node\\Learnapp\\node_modules\\loopback\\common\\models\\role.js:436:21\n at _combinedTickCallback (internal/process/next_tick.js:131:7)\n at process._tickCallback (internal/process/next_tick.js:180:9)" } }
even when i put the token in access token

any idea ?

Francois Laforge

unread,
Oct 13, 2017, 10:26:00 AM10/13/17
to LoopbackJS
Check your ACLS.  Maybe the user you are using does not have access to your model for what you want to do.

Reply all
Reply to author
Forward
0 new messages