How to pass over camera parameter?

I want to use the camera function in the app, but I don't know how to pass over the parameters.

var camera='luna://com.webos.service.camera2/getCameraList';
var camerapar='{}';

var cameraopen='luna://com.webos.service.camera2/open';
var cameraopenpar='{"id":"camera1"}';,camerapar);,cameraopenpar);
var camerapreview='luna://com.webos.service.camera2/startPreview'; 
var camerapreviewpar='{ "handle":3917, "params": {"type":"sharedmemory","source":"0"}}';,camerapreviewpar);

I tried in this way, but I'm having a difficulty delivering the handle parameters, how can I solve it?

Refer to this code snippet. you will need a callback function