IBM DataPower Operations Dashboard v1.0.21.x
A newer version of this product documentation is available.
You are viewing an older version. View latest at IBM DPOD Documentation.
Roles REST API
- Sara Weisz
Available Roles actions via APIs
Get Custom / Get Builtin/ Create Custom / Update / Delete Roles
Authorization:
Authentication: Basic authentication
Roles: it is recommended to read Role Based Access Control page for understanding build-in and custom roles permissions.
From CLI (example):
curl -u username:password https://<dpod hostname>/op/api/v2/roles
GET Retrieve All Custom Roles
URL:
GET - https://{{dpodHostname}}
/op/api/v2/roles
/custom
Authorization:
Required Permissions | More info |
---|
Required Permissions | More info |
---|---|
| See roles information here: Role Based Access Control |
Response:
Response Type | Example value | Description |
---|
Response Type | Example value | Description |
---|---|---|
Successful | {
"resultCode": "SUCCESS",
"resultMessage": "Custom roles retrieved successfully.",
"result": {
"roles": [
{
"id": 5,
"name": "customRole",
"roleType": "CUSTOM_ROLE",
"description": "",
"rolePreferenceDtos": []
},
{
"id": 6,
"name": "customRole2",
"roleType": "CUSTOM_ROLE",
"description": "",
"rolePreferenceDtos": []
}
]
}
} | Status code: 200 resultCode → SUCCESS resultMessage → “Custom roles retrieved successfully"
|
GET Retrieve All Builtin Roles
URL:
GET - https://{{dpodHostname}}
/op/api/v2/roles
/builtin
Authorization:
Required Permissions | More info |
---|
Required Permissions | More info |
---|---|
| See roles information here: Role Based Access Control |
Response:
Response Type | Example value | Description |
---|
Response Type | Example value | Description |
---|---|---|
Successful | {
"resultCode": "SUCCESS",
"resultMessage": "Builtin roles retrieved successfully.",
"result": {
"roles": [
{
"id": 1,
"name": "OpDashAdminRole",
"roleType": "BUILTIN_ROLE",
"description": "Built-in role for administrators (can do everything)",
"rolePreferenceDtos": []
},
{
"id": 4,
"name": "OpDashInvestigatorRole",
"roleType": "BUILTIN_ROLE",
"description": "Built-in role for investigators (some dashboards, troubleshoot, investigate)",
"rolePreferenceDtos": []
},
{
"id": 3,
"name": "OpDashOperatorRole",
"roleType": "BUILTIN_ROLE",
"description": "Built-in role for controllers (dashboards, troubleshoot, investigate)",
"rolePreferenceDtos": []
},
{
"id": 2,
"name": "OpDashPowerUserRole",
"roleType": "BUILTIN_ROLE",
"description": "Built-in role for power users (dashboards, troubleshoot, investigate, execute reports, view devices/domains/services)",
"rolePreferenceDtos": []
}
]
}
} | Status code: 200 resultCode → SUCCESS resultMessage → “Builtin roles retrieved successfully"
|
GET Get Specific Custom Role Details
URL:
GET - https://{{dpodHostname}}
/op/api/v2/role
/custom/{{roleId}}
URL Parameters:
Name | Is required | Description | Parameter Type |
---|
Name | Is required | Description | Parameter Type |
---|---|---|---|
roleId | True | The role id (can be retrieved from “Retrieve All Custom Roles” response) | Number |
Authorization:
Required Permissions | More info |
---|
Required Permissions | More info |
---|---|
| See roles information here: Role Based Access Control |
Response:
Response Type | Example value | Description |
---|
Response Type | Example value | Description |
---|---|---|
Successful | Status code: 200 resultCode → SUCCESS resultMessage → “Role retrieved successfully” |
POST Add Custom Role
URL:
POST - https://{{dpodHostname}}
/op/api/v2/roles/custom
Authorization:
Required Permissions | More info |
---|
Required Permissions | More info |
---|---|
| See roles information here: Role Based Access Control |
Request body:
Type | Parameters | Example Json | Description |
---|
Type | Parameters | Example Json | Description |
---|---|---|---|
Required |
|
|
Response:
Response Type | Example value | Description |
---|
Response Type | Example value | Description |
---|---|---|
Successful | Status code: 200 resultCode → SUCCESS resultMessage → “Custom role added successfully” |
put Update Custom Role
URL:
PUT - https://{{dpodHostname}}
/op/api/v2/role/custom/{{roleId}}
URL Parameters:
Name | Is required | Description | Parameter Type |
---|
Name | Is required | Description | Parameter Type |
---|---|---|---|
roleId | True | The role id (can be retrieved from “Retrieve All Custom Roles” response) | Number |
Authorization:
Required Permissions | More info |
---|
Required Permissions | More info |
---|---|
| See roles information here: Role Based Access Control |
Request:
Type | Parameters | Example Json | Description |
---|
Type | Parameters | Example Json | Description |
---|---|---|---|
Required |
|
|
Response:
Response Type | Example value | Description |
---|
Response Type | Example value | Description |
---|---|---|
Successful | Status code: 200 resultCode → SUCCESS resultMessage → “Custom role updated successfully” |
DELETE Delete Custom Role
Copyright © 2015 MonTier Software (2015) Ltd.