connected-app-client-sdk
v1.0.11
Published
Client SDK for developing connected app that can be installed on orbro platform.
Downloads
4
Readme
Orbro Connected APP Client SDK
Client SDK for developing connected app that can be installed on orbro platform.
Installation
Using npm:
npm install connected-app-client-sdk
Connect app initialization:
import sdk from "connect-app-client-sdk"; try { const connectedApp = await sdk.init(); } catch (error) { console.error(error); }
connectedApp:
{ defaultData, // Initial Data Set originToken, // Token }
API
openDialog:
Open Dialog in ORBRO platform
sdk.openDialog(options);
options:
{ title: 'title', // Dialog title text: 'text', // Dialog text callbackList: callbackList // Dialog button setting }
callbackList:
[ { name: "cancelCallback", // callback name fn: doCancel, // callback function label: "Cancel", // button label }, { name: "confirmCallback", fn: doConfirm, label: "Confirm", }, ];
closeDialog:
- Close Dialog in ORBRO platform
sdk.closeDialog();
openToast:
Open Toast in ORBRO platform
sdk.openToast(options);
options:
{ text: '', // Toast text callbackList: callbackList // Toast button setting }
callbackList:
[ { name: "cancelCallback", // callback name fn: doCancel, // callback function label: "Cancel", // button label }, { name: "confirmCallback", fn: doConfirm, label: "Confirm", }, ];
closeToast:
- Close Toast in ORBRO platform
sdk.closeToast();
getToken:
- Get token
sdk.getToken();
getDefaultData:
- Get selected 3D object data
sdk.getDefaultData();
Get More Info at Orbro Platform Introduction Page.