Join us on May 14-15, 2019 at Forrester Digital Transformation & Innovation 2019 in Chicago, USA.

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3
Table of Contents

web/json/app/(:appId)/(~:appVersion)/plugin/(*:pluginName)/service

URL

web/json/app/(:appId)/(~:appVersion)/plugin/(*:pluginName)/service

Method

GET/POST

Description

This plugin serves as the generic access point to any plugin that implements PluginWebSupport in the context of a specific App and App version.

It will call the webService method in the specificied plugin. Thus, the number of parameters needed essentially depends on the plugin itself.

Parameters

Name

Mandatory

Description

appId

Yes

Application ID (e.g. leaveApp)

appVersion

 

Application Version (e.g. 2)
Default: Latest version

pluginName

Yes

Plugin Class Path (E.g. org.joget.apps.userview.lib.InboxMenu)

Sample Call

http://localhost:8080/jw/web/json/app/leaveApp/2/plugin/org.joget.apps.userview.lib.InboxMenu/service?action=getProcesses

Sample Resul

Code Block
[
   {
      "value":"",
      "label":""
   },
   {
      "value":"leaveProcess",
      "label":"Leave Process (leaveProcess)"
   }
]

web/json/plugin/(*:pluginName)/service

URL

web/json/plugin/(*:pluginName)/service

Method

GET/POST

Description

This plugin serves as the generic access point to any plugin that implements PluginWebSupport without being in the context of a specific App and App version.

It will call the webService method in the specificied plugin. Thus, the number of parameters needed essentially depends on the plugin itself.

Parameters

Name

Mandatory

Description

pluginName

Yes

Plugin Class Path (E.g. plugin/org.joget.apps.userview.lib.InboxMenu)

Sample Call

http://localhost:8080/jw/web/json/plugin/org.joget.apps.userview.lib.UserPermission/service?action=getUsers

Sample Result

Code Block
[  
   {  
      "value":"admin",
      "label":"Admin Admin(admin)"
   },
   {  
      "value":"cat",
      "label":"Cat Grant(cat)"
   },
   {  
      "value":"clark",
      "label":"Clark Kent(clark)"
   },
   {  
      "value":"david",
      "label":"David Cain(david)"
   }
]

web/json/hash/options

URL

web/json/hash/options

Method

GET

Description

This is the utility call used to list down all hash variables' availableSyntax for autocomplete purpose.

Parameters

Name

Mandatory

Description

Sample Call

http://localhost:8080/jw/web/json/hash/options

Sample Result

Code Block
[
   "assignment.activityDefId",
   "assignment.activityId",
   "assignment.activityName",
   "assignment.assigneeId",
   "assignment.processDefId",
   "assignment.processId",
   "assignment.processName",
   "assignment.processRequesterId",
   "assignment.processVersion",
   "currentUser.active",
   "currentUser.department.description",
   "currentUser.department.id",
   "currentUser.department.name",
   "currentUser.email",
   "currentUser.employee.code",
   "currentUser.employee.isHod",
   "currentUser.employee.jobTitle",
   "currentUser.firstName",
   "currentUser.grade.description",
   "currentUser.grade.id",
   "currentUser.grade.name",
   "currentUser.groups.id",
   "currentUser.groups.name",
   "currentUser.hod.active",
   "currentUser.hod.email",
   "currentUser.hod.firstName",
   "currentUser.hod.lastName",
   "currentUser.hod.timeZone",
   "currentUser.hod.username",
   "currentUser.lastName",
   "currentUser.organization.description",
   "currentUser.organization.id",
   "currentUser.organization.name",
   "currentUser.timeZone",
   "currentUser.username",
   "date.DAY+INTEGER.FORMAT",
   "date.DAY-INTEGER.FORMAT",
   "date.FORMAT",
   "date.MONTH+INTEGER.FORMAT",
   "date.MONTH-INTEGER.FORMAT",
   "date.YEAR+INTEGER.FORMAT",
   "date.YEAR-INTEGER.FORMAT",
   "envVariable.KEY",
   "form.TABLE.COLUMN",
   "form.TABLE.COLUMN[PRIMARY_KEY]",
   "i18n.KEY",
   "performer.ACTIVITY_DEF_ID.active",
   "performer.ACTIVITY_DEF_ID.email",
   "performer.ACTIVITY_DEF_ID.firstName",
   "performer.ACTIVITY_DEF_ID.id",
   "performer.ACTIVITY_DEF_ID.lastName",
   "performer.ACTIVITY_DEF_ID.timeZone",
   "performer.ACTIVITY_DEF_ID.username",
   "requestParam.KEY",
   "user.USERNAME.active",
   "user.USERNAME.department.description",
   "user.USERNAME.department.id",
   "user.USERNAME.department.name",
   "user.USERNAME.email",
   "user.USERNAME.employee.code",
   "user.USERNAME.employee.isHod",
   "user.USERNAME.employee.jobTitle",
   "user.USERNAME.firstName",
   "user.USERNAME.grade.description",
   "user.USERNAME.grade.id",
   "user.USERNAME.grade.name",
   "user.USERNAME.groups.id",
   "user.USERNAME.groups.name",
   "user.USERNAME.hod.active",
   "user.USERNAME.hod.email",
   "user.USERNAME.hod.firstName",
   "user.USERNAME.hod.lastName",
   "user.USERNAME.hod.timeZone",
   "user.USERNAME.hod.username",
   "user.USERNAME.lastName",
   "user.USERNAME.organization.description",
   "user.USERNAME.organization.id",
   "user.USERNAME.organization.name",
   "user.USERNAME.timeZone",
   "user.USERNAME.username",
   "variable.KEY"
]

web/json/console/app/(*:appId)/(~:version)/datalist/options

URL

web/json/console/app/(*:appId)/(~:version)/datalist/options

Method

GET

Description

List all Datalists in of a specific App and App version

Parameters

Name

Mandatory

Description

appId

Yes

Application ID (e.g. leaveApp)

version

 

Application Version (e.g. 2)
Default: Latest version

callback

 

Javascript callback function name

sort

 

Sort column
Default: name

desc

 

Decending
true / false

start

 

Start row count
Integer

rows

 

Return row count
Integer

Sample Call

http://localhost:8080/jw/web/json/console/app/leaveApp/2/datalist/options

Sample Result

Code Block
[
   {
      "value":"",
      "label":""
   },
   {
      "value":"applicationList",
      "label":"Application List"
   },
   {
      "value":"contactList",
      "label":"Contact List"
   },
   {
      "value":"userApplicationList",
      "label":"User Application List"
   }
]

web/json/console/app/(*:appId)/(~:version)/forms/options

URL

web/json/console/app/(*:appId)/(~:version)/forms/options

Method

GET

Description

List all Forms in of a specific App and App version

Parameters

Name

Mandatory

Description

appId

Yes

Application ID (e.g. leaveApp)

version

 

Application Version (e.g. 2)
Default: Latest version

callback

 

Javascript callback function name

sort

 

Sort column
Default: name

desc

 

Decending
true / false

start

 

Start row count
Integer

rows

 

Return row count
Integer

Sample Call

http://localhost:8080/jw/web/json/console/app/leaveApp/2/forms/options

Sample Result

Code Block
[
   {
      "value":"",
      "label":""
   },
   {
      "value":"submitLeaveForm",
      "label":"1-Submit Leave Form"
   },
   {
      "value":"approveLeaveForm",
      "label":"2-Approve Leave Form"
   },
   {
      "value":"leaveApprovedForm",
      "label":"3-Leave Approved Form"
   }
]

web/json/console/app/(*:appId)/(~:version)/userview/options

URL

web/json/console/app/(*:appId)/(~:version)/userview/options

Method

GET

Description

List all Userviews in of a specific App and App version

Info

Available in Joget version 5

Parameters

Name

Mandatory

Description

appId

Yes

Application ID (e.g. leaveApp)

version

 

Application Version (e.g. 2)
Default: Latest version

callback

 

Javascript callback function name

sort

 

Sort column
Default: name

desc

 

Decending
true / false

start

 

Start row count
Integer

rows

 

Return row count
Integer

Sample Call

http://localhost:8080/jw/web/json/console/app/leaveApp/2/userview/options

Sample Result

web/property/json/getElements

URL

web/property/json/getElements

Method

GET

Description

Return a list of plugins of the given type.

Parameters

Name

Mandatory

Description

className

Yes

Plugin Class Path (E.g. org.joget.apps.userview.model.UserviewPermission)

Sample Call

http://localhost:8080/jw/web/property/json/getElements?classname=org.joget.apps.userview.model.UserviewPermission

Sample Result

Code Block
[
   {
      "value":"",
      "label":""
   },
   {
      "value":"org.joget.plugin.enterprise.AdminUserviewPermission",
      "label":"Is Admin"
   },
   {
      "value":"org.joget.plugin.enterprise.AnonymousUserviewPermission",
      "label":"Is Anonymous"
   },
   {
      "value":"org.joget.apps.userview.lib.BeanShellPermission",
      "label":"Bean Shell Script"
   },
   {
      "value":"org.joget.apps.userview.lib.DepartmentPermission",
      "label":"Department"
   },
   {
      "value":"org.joget.apps.userview.lib.GroupPermission",
      "label":"Group"
   },
   {
      "value":"org.joget.apps.userview.lib.LoggedInUserPermission",
      "label":"Logged In User"
   },
   {
      "value":"org.joget.apps.userview.lib.OrganizationPermission",
      "label":"Organization"
   },
   {
      "value":"org.joget.plugin.enterprise.SubLevelUserviewPermission",
      "label":"Is Sub Level Userview"
   },
   {
      "value":"org.joget.apps.userview.lib.UserPermission",
      "label":"User"
   }
]

web/property/json/getPropertyOptions

URL

web/property/json/getPropertyOptions

Method

GET

Description

Calls the getPropertyOptions() method of the given plugin. This is used primarily in the property editor of Joget to dynamically construct the properties.

Parameters

Name

Mandatory

Description

value

Yes

Plugin class path (e.g.org.joget.apps.userview.lib.UserPermission)

Sample Call

http://localhost:8080/jw/web/property/json/getPropertyOptions?value=org.joget.apps.userview.lib.UserPermission

Sample Result

Code Block
[
   {
      title:'Configure Userview Permission (User)',
      properties:[
         {
            name:'orgId',
            label:'Select Organization',
            type:'selectbox',
            options_ajax:'[CONTEXT_PATH]/web/json/plugin/org.joget.apps.userview.lib.UserPermission/service?action=getOrgs'
         },
         {
            name:'allowedUsernames',
            label:'Select Users',
            type:'multiselect',
            size:'10',
            options_ajax_on_change:'orgId',
            options_ajax:'[CONTEXT_PATH]/web/json/plugin/org.joget.apps.userview.lib.UserPermission/service?action=getUsers'
         }
      ]
   }
]

web/property/json/(*:appId)/(~:version)/getPropertyOptions

URL

Method

Description

Calls the getPropertyOptions() method of the given plugin in a App context. This is used primarily in the property editor of Joget to dynamically construct the properties.

Parameters

Name

Mandatory

Description

appId

Yes

Application ID (e.g. leaveApp)

version

 

Application Version (e.g. 2)
Default: Latest version

value

Yes

Plugin class path (e.g.org.joget.apps.userview.lib.UserPermission)

Sample Call

http://localhost:8080/jw/web/property/json/leaveApp/2/getPropertyOptions?value=org.joget.apps.form.lib.DefaultValidator

Sample Result

Code Block
[
   {
      title:'Configure Validator',
      properties:[
         {
            name:'mandatory',
            label:'Mandatory',
            type:'checkbox',
            value:'true',
            options:[
               {
                  value:'true',
                  label:''
               }
            ]
         },
         {
            name:'type',
            label:'Type',
            type:'selectbox',
            options:[
               {
                  label:'',
                  value:''
               },
               {
                  label:'Alphabet',
                  value:'alphabet'
               },
               {
                  label:'Alphanumeric',
                  value:'alphanumeric'
               },
               {
                  label:'Numeric',
                  value:'numeric'
               },
               {
                  label:'Email',
                  value:'email'
               },
               {
                  label:'Custom Regular Expression',
                  value:'custom'
               }
            ]
         },
         {
            name:'custom-regex',
            label:'Custom Regular Expression',
            type:'textfield'
         },
         {
            name:'message',
            label:'Custom Error Message Shown When Validation Fail ',
            type:'textfield'
         }
      ]
   }
]

web/property/json/(*:appId)/(~:version)/getDefaultProperties

URL

web/property/json/(*:appId)/(~:version)/getDefaultProperties

Method

GET

Description

To get plugin default properties of a given class path in a App context.

Info

Available in Joget version 5

Parameters

Name

Mandatory

Description

appId

Yes

Application ID (e.g. leaveApp)

version

 

Application Version (e.g. 2)
Default: Latest version

value

Yes

Plugin class path (e.g.org.joget.apps.userview.lib.UserPermission)

Sample Call

http://localhost:8080/jw/web/property/json/hr_expense/2/getDefaultProperties?value=org.joget.apps.app.lib.EmailTool

Sample Result

Code Block
{
   "host":"smtp.gmail.com",
   "port":"465",
   "security":"",
   "username":"",
   "password":"****SECURE_VALUE****-0",
   "from":"test@test.com",
   "toSpecific":"",
   "toParticipantId":"",
   "cc":"",
   "bcc":"",
   "subject":"",
   "message":"",
   "isHtml":"",
   "formDefId":"",
   "fields":[

   ],
   "files":[

   ]
}