1. Home
  2. Docs
  3. API
  4. Sessions resource
  5. Create a new session

Create a new session

REQUEST
POST
{
idChannel: 0,
idAgent: xxxxxxxxxxxxxxxx
locale: en
fullAccess: false,
hideAppsBar: true,
postMessageOrigin: www.mysite.com,
applications: {
desktop: {
fullAccess: true,
},
filesystem: {
fullAccess: false,
paths: [
{
name: path1,
path: c:\\test,
edit: true,
download: true,
upload: true
},
...
],
...
},
...
}
}

RESPONSE
200 OK
{
idChannel: channel id (same of request),
url: url of session
tempcode: temporary code (present only if idAgent is empty).
}

The information to create a session is:

idChannel:Identify the channel id.
idAgent:Identify the agent id (if omitted, create a temporary session).
fullAccess:true or false
applications:List of application allowed. (Valid if fullAccess=false). The available applications are: desktop, filesystem, texteditor, resource, logwatch, shell
hideAppsBar:true/false (default false) hide menu apps.
showAppOnLoad:Show app specified when session is loaded. (valid only if you have defined more of one app in applications)
postMessageOrigin:If you want show content inside of IFrame you have to set your domain (e.g. https://www.company.com).

If fullAccess is false, you have to specify the list of allowed applications :

Desktop :

fullAccess:true or false
allowScreenInput:Allow user input. (Valid if fullAccess=false)
allowAudio:Allow remote audio. (Valid if fullAccess=false)
hideToolBar:Hide the toolbar. (true/false)
backgroundColor:Change background color. (e.g. "#ffffff")
messageBackgroundColor:Change message background color. (e.g. "#ffffff")
messageColor:Change message color. (e.g. "#000000")

FileSystem:

fullAccess:true or false
paths:Shows to user only specified path list.(Valid if fullAccess=false).
The path information are:
  • name: Name shown to the user.
  • path: The real directory path.
  • edit: Allow edit (true or false).
  • download: Allow download (true or false).
  • upload: (true or false).

TextEditor:

fullAccess:true or false
paths:Shows to user only specified path list. (Valid if fullAccess=false).
The path information are:
  • name: Name shown to the user.
  • path: The real directory path.
  • edit: Allow edit (true or false).

LogWatch:

fullAccess:true or false
paths:Shows to user only specified path list. (Valid if fullAccess=false).
The path information are:
  • name: Name shown to the user.
  • path: The real directory path.

Resource:

fullAccess:true

Shell:

fullAccess:true