Zeige mehr…

Navigation Menu Editor REST API

Get information about the Navigation Menu Editors developer resources

JavaScript API

If you want to create the menu markup yourself, we have created a JavaScript component with which you can get the menu structure for the current user in JSON format.

/** * Get the JSON representation for the menu of the current user. * @param callback Function to process JSON, e.g. processJSON(Object menuJson){ ... } */ SeibertMedia.MenuEditor.MenuBuilder.buildJsonMenu(function callback)

Navigation Menu Editor REST API

REST API Resources

Navigation structure

Resource Description Permission
GET menueditor/1.0/menu Returns the navigation structure in JSON format Everyone

Returns the unfiltered navigation structure in JSON format Admins, Editors
GET menueditor/1.0/menu/backup/{backupKey} Returns the backuped navigation structure in JSON format Admins, Editors
Ends the locked session of the current menu editor Everyone

Menu Editor Configuration and user fields

Resource Description Permission
GET menueditor/1.0/configuration Retrieve the list of fields, that are configured for filtering Everyone
 GET linchpin/1.0/fields Returns the possible user fields Everyone
Checks Custom User Profile Plugin is installed Everyone

Menu Editor profile and permissions

Resource Description Permission
Returns true or false if the current logged in user has permission to edit the navigation structure Everyone

Get a list of all permitted users and groups Admin
Grant edit permission to a user or group Admin
DELETE menueditor/1.0/permissions/{name} Revoke edit permission of a user or group Admin

Get the user profile data of a user Everyone

Menue Resource Details

GET menueditor/1.0/menu

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/menu

Parameters

filter0

Specifies the value for the first set up user field.
e.g. If you have set up the Confluence locale as your first user field, you might set filter0=en_GB to get the navigation structure for an english user.

filter1 Same as above. Filter value for the second set up user field.
filter2 Same as above. Filter value for the third set up user field.

Result (Example)

{ "entries":[ { "title":"Kategorie 1", "type":"category", "targetBlank":false, "menu":{ "entries":[ { "title":"Item 1.1", "link":"http://www.example.com", "type":"entry", "targetBlank":false }, { "title":"Item 1.2", "link":"http://www.example.com", "type":"entry", "targetBlank":false }, { "title":"Kat 1.3", "type":"category", "targetBlank":false }, { "title":"Item 1.5 (mit Unterelementen)", "link":"http://www.example.com", "type":"entry", "targetBlank":false, "menu":{ "entries":[ { "title":"Kat 1.5.1", "type":"category", "targetBlank":false }, { "title":"Item 1.5.2", "link":"http://www.example.com", "type":"entry", "targetBlank":false } ] } } ] } }, { "title":"Kategorie 2", "type":"category", "targetBlank":false, "menu":{ "entries":[ { "title":"Item 2.1", "link":"http://www.example.com", "type":"entry", "targetBlank":false }, { "type":"separator", "targetBlank":false }, { "title":"Item 2.3", "link":"http://www.example.com", "type":"entry", "targetBlank":false }, { "title":"Item 2.4 (ohne Link)", "link":"", "type":"entry", "targetBlank":false } ] } } ] }

GET menueditor/1.0/menu/unfiltered

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/menu/unfiltered

Parameters

-

Result (Example)

Have a look at GET menueditor/1.0/menu

GET menueditor/1.0/menu/backup/{backupKey}

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/menu/unfiltered

Parameters

-

Result (Example)

Have a look at GET menueditor/1.0/menu

DELETE menueditor/1.0/lockservice/unlock

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/lockservice/unlock

Parameters

-

Result

null

GET menueditor/1.0/configuration

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/configuration

Parameters

-

Result (Example)

[ "confluece.locale", "cup.location-5", "cup.department-7" ]

GET linchpin/1.0/fields

Resource URL: <HOST><CONTEXT>/rest/linchpin/1.0/fields

Parameters

-

Result (Example)

[ { "userFieldBK": "confluence.name", "labelPropertyKey": "Name" }, { "userFieldBK": "confluence.email", "labelPropertyKey": "Email" }, { "userFieldBK": "confluence.fullname", "labelPropertyKey": "Fullname" }, { "userFieldBK": "confluence.locale", "labelPropertyKey": "Locale" } ]

GET linchpin/1.0/cupinstalled

Resource URL: <HOST><CONTEXT>/rest/linchpin/1.0/cupinstalled

Parameters

-

Result (Example)

false

GET menueditor/1.0/permissions/check

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/permissions/check

Parameters

-

Result (Example)

{ "permitted":true }

GET menueditor/1.0/permissions

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/permissions

Parameters

-

Result (Example)

{ "permissions": [ { "name": "editor", "type": "user", "fullname": "Eddi Editor" }, { "name": "Editors", "type": "group" } ] }

POST menueditor/1.0/permissions

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/permissions

Parameters

name Name of the user or group that should be permitted to edit the menu

Result (Example)

{ "permissions": [ { "name": "editor", "type": "user", "fullname": "Eddi Editor" }, { "name": "Editors", "type": "group" } ] }

DELETE menueditor/1.0/permissions/{name}

Resource URL: <HOST><CONTEXT>/rest/menueditor/1.0/permissions/{name}

Parameters

name Name of the user or group that should be removed

Result (Example)

{ "permissions": [ { "name": "editor", "type": "user", "fullname": "Eddi Editor" }, { "name": "Editors", "type": "group" } ] }

GET linchpin/1.0/profile

Resource URL: <HOST><CONTEXT>/rest/linchpin/1.0/profile

Parameters

-

Result

{ "confluence.fullname": "admin", "confluence.name": "admin", "confluence.locale": "de_DE", "confluence.email": "admin@example.com" }
Zeige mehr…
Zeige mehr…