User Authorizations API documentation version v1
Application_URL/services/api/v1
About User Authorizations
You use this feature to define a more granular access to asset modeling business objects for users within your organization.
Purpose
This API allows you to create, update, retrieve, delete organizational hierarchy.
/user-auth/organization/units
This endpoint allows you to create an organization unit.
post /user-auth/organization/units
This endpoint allows you to create an organization unit.
REST API supports Basic Authentication
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"parentGroupId": {
"type": "string",
"maxLength": 32,
"description": "Parent Organization unit ID. Can be empty for the root Organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
},
"required": ["short"]
}
},
"required": ["name", "parentGroupId", "description"]
}Example:
{
"name": "Org Unit 1",
"parentGroupId": "218919B3DD2240A597CAEA3CA75B02C9",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 200
Successfully creates an organization unit.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"id": {
"type": "string",
"maxLength": 32,
"description": "System generated organization unit ID."
},
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"parentGroupId": {
"type": "string",
"maxLength": 32,
"description": "Parent Organization unit ID. Can be empty for the root Organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
}
}
}
}Example:
{
"id": "43D0EDB91E484E3295B8668E302C0B86",
"name": "Org Unit 1",
"parentGroupId": "218919B3DD2240A597CAEA3CA75B02C9",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}/user-auth/organization/units({groupId})/header
This endpoint allows you to update header information of an organization unit.
This endpoint allows you to read header information of an organization unit.
put /user-auth/organization/units({groupId})/header
This endpoint allows you to update header information of an organization unit.
REST API supports Basic Authentication
URI Parameters
- groupId: required (string)
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
},
"required": ["short"]
}
},
"required": ["name", "description"]
}Example:
{
"name": "Org Unit 1",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 200
Successfully creates an organization unit.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"id": {
"type": "string",
"maxLength": 32,
"description": "System generated organization unit ID."
},
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"parentGroupId": {
"type": "string",
"maxLength": 32,
"description": "Parent Organization unit ID. Can be empty for the root Organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
}
}
}
}Example:
{
"id": "43D0EDB91E484E3295B8668E302C0B86",
"name": "Org Unit 1",
"parentGroupId": "218919B3DD2240A597CAEA3CA75B02C9",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 400
Bad request, when organization unit doesn't exists or organization name is duplicated.
get /user-auth/organization/units({groupId})/header
This endpoint allows you to read header information of an organization unit.
REST API supports Basic Authentication
URI Parameters
- groupId: required (string)
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
},
"required": ["short"]
}
},
"required": ["name", "description"]
}Example:
{
"name": "Org Unit 1",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 200
Successfully read header information for an organization unit.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"id": {
"type": "string",
"maxLength": 32,
"description": "System generated organization unit ID."
},
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"parentGroupId": {
"type": "string",
"maxLength": 32,
"description": "Parent Organization unit ID. Can be empty for the root Organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
}
}
}
}Example:
{
"id": "43D0EDB91E484E3295B8668E302C0B86",
"name": "Org Unit 1",
"parentGroupId": "218919B3DD2240A597CAEA3CA75B02C9",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 400
Bad request, when organization unit doesn't exists.
/user-auth/organization/units({groupId})
This endpoint allows you to delete an organization unit.
delete /user-auth/organization/units({groupId})
This endpoint allows you to delete an organization unit.
REST API supports Basic Authentication
/user-auth/organization/units/structure
This endpoint allows read organization unit structure.
get /user-auth/organization/units/structure
This endpoint allows read organization unit structure.
REST API supports Basic Authentication
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
},
"required": ["short"]
}
},
"required": ["name", "description"]
}Example:
{
"name": "Org Unit 1",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 200
Successfully read header information for an organization unit.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"id": {
"type": "string",
"maxLength": 32,
"description": "System generated organization unit ID."
},
"name": {
"type": "string",
"maxLength": 255,
"description": "Name of organization unit."
},
"parentGroupId": {
"type": "string",
"maxLength": 32,
"description": "Parent Organization unit ID. Can be empty for the root Organization unit."
},
"description": {
"type": "object",
"properties": {
"short": {
"type": "string",
"maxLength": 255,
"description": "Short description"
},
"long": {
"type": "string",
"maxLength": 5000,
"description": "Long description"
}
}
}
}
}Example:
{
"id": "43D0EDB91E484E3295B8668E302C0B86",
"name": "Org Unit 1",
"parentGroupId": "218919B3DD2240A597CAEA3CA75B02C9",
"description": {
"short": "Org Unit 1",
"long": "Org Unit 1"
}
}HTTP status code 400
Bad request, when organization unit doesn't exists
/user-auth/organization/units({groupId})/objects
This endpoint allows you to add/remove business objects to an organization unit.
put /user-auth/organization/units({groupId})/objects
This endpoint allows you to add/remove business objects to an organization unit.
REST API supports Basic Authentication
URI Parameters
- groupId: required (string)
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"objectId": {
"type": "string",
"maxLength": 32,
"description": "Business object ID."
},
"objectType": {
"type": "string",
"enum": [
"PRO", "PST", "CAT", "MOD", "EQU", "DOC", "ANN", "INS", "FL", "PRT", "GRP", "FM", "SYS"
],
"maxLength": 3,
"description": "Business object type. PRO - Attribute, PST - Attribute Group, CAT - Template, MOD - Model, EQU - Equipment, DOC - document, ANN - Announcement, INS - Instruction, FL - Location, PRT - Spare part, GRP - Group, FM - Failure Mode, SYS - System."
},
"operation": {
"type": "string",
"enum": [
"add", "remove"
],
"maxLength": 10,
"description": "The operation that needs to be performed on the business object. 'add' - Add the business object to organization unit, 'remove' - Remove the business object from organization unit."
}
}
}Example:
[{
"objectId": "5405036E54944649B439DCC769486167",
"objectType": "EQU",
"operation": "add"
}, {
"objectId": "8E8985E2730946AB9A5A8DDB31196968",
"objectType": "EQU",
"operation": "add"
}, {
"objectId": "97FB7E44F89249F3BD4989176532D806",
"objectType": "EQU",
"operation": "remove"
}]HTTP status code 204
Successfully updated objects to an organization unit.
HTTP status code 400
Bad request, when organization unit doesn't exists or the logged on user is not authorized to add/remove the objects to organization unit.
/user-auth/organization/units({groupId})/members
This endpoint allows you to add/remove/update users in an organization unit.
put /user-auth/organization/units({groupId})/members
This endpoint allows you to add/remove/update users in an organization unit.
REST API supports Basic Authentication
URI Parameters
- groupId: required (string)
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"userId": {
"type": "string",
"maxLength": 32,
"description": "32 character UUID generated by the system."
},
"accessPrivilege": {
"type": "string",
"enum": [
"READ", "WRITE", "DELETE"
],
"maxLength": 3,
"description": "Authorization to be given to the user in the organization unit."
},
"operation": {
"type": "string",
"enum": [
"add", "remove", "update"
],
"maxLength": 10,
"description": "The operation that needs to be performed on the user. 'add' - Add the user to organization unit, 'remove' - Remove the user from organization unit. 'update' - Update the access privilege of the user in organization unit."
}
}
}Example:
[{
"userId": "0F51C04297884FA1B9945AB8ACC49C67",
"accessPrivilege": "READ",
"operation": "add"
}, {
"userId": "85D5E5F8606E4B399FB4E7249957CF5A",
"accessPrivilege": "DELETE",
"operation": "update"
}, {
"userId": "632450BA6B694D0288ED068281A44487",
"accessPrivilege": "WRITE",
"operation": "remove"
}]HTTP status code 204
Successfully updated users in an organization unit.
HTTP status code 400
Bad request, when organization unit doesn't exists or users you are trying to update are not valid.