Device List Type REST Service

Use Device List Type REST Service to obtain a list of device groups for the device type you specified.

Defined in

Device types
Operation
Get
URL
To retrieve a list for all device types:
https://<host>:<port>/SKLM/rest/v1/deviceTypes
To retrieve a list for a single device type:
https://<host>:<port>/SKLM/rest/v1/deviceTypes<deviceListType>
To retrieve a list for multiple device types:
https://<host>:<port>/SKLM/rest/v1/deviceTypes?deviceListType=<value>

By default, Guardium® Key Lifecycle Manager server listens to the secure port 9443 (HTTPS) for communication. During IBM® Security Guardium Key Lifecycle Manager installation, you can modify this default port.

Request

Request parameters
Parameter Description
host Specify the IP address or host name of the IBM Security Guardium Key Lifecycle Manager server.
port Specify the port number on which the IBM Security Guardium Key Lifecycle Manager server listens for requests.
deviceListType Optional. Specify the device list type for which the list of device groups are to be returned. Device lists for all the types are returned if you do not specify this parameter.
You can specify any of the following values:
  • admin
  • rollover
  • step
You can specify multiple comma-separated values.
Request Headers
Header name Value
Content-Type application/json
Accept application/json
Authorization SKLMAuth userAuthId=<authIdValue>
Accept-Language Any valid locale that is supported by IBM Security Guardium Key Lifecycle Manager. For example, en or de.

Response

Response Headers
Header name Value and description
Status Code
200 OK
The request was successful. The response body contains the requested representation.
400 Bad Request
The authentication information was not provided in the correct format.
401 Unauthorized
The authentication credentials were missing or incorrect.
404 Not Found Error
The processing of the request fails.
500 Internal Server Error
The processing of the request fails because of an unexpected condition on the server.
Content-Type application/json
Content-Language Locale for the response message.
Success response body

JSON Object with the following specification:

JSON property name Description
deviceListType (admin, step, rollover) Returns the JSON object of device list type, such as admin, step, or rollover.

The JSON object contains a list of device groups with JSON device object as specified in the following JSON device object table.

JSON device object
JSON property name Description
name Contains the device group name.
label Contains the device group label name.
Error Response Body

JSON object with the following specification.

JSON property name Description
code Returns the application error code.
message Returns a message that describes the error.

Examples

Service request to get device list of all types
GET https://<host>:<post>/SKLM/rest/v1/deviceTypes
Content-Type: application/json
Accept : application/json
Authorization : SKLMAuth userAuthId=37ea1939-1374-4db7-84cd-14e399be2d20
Accept-Language : en
Success response
Status Code : 200 OK
Content-Language: en
{“admin”:
{"items":
    [{ ‘’name’’:‘’LTO001‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d20’’
    },
    { ‘’name’’:”DISK002‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d21’’
    }],"identifier":"name"},
“rollover”:
{"items":
    [{‘’name’’:‘’LTO001‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d20’’
    },
    { ‘’name’’:”DISK002‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d21’’
    }],"identifier":"name"},
“step”:
{"items":
    [{‘’name’’:‘’LTO001‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d20’’
    },
    { ‘’name’’:”DISK002‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d21’’
    }],"identifier":"name"}
}
Service request to get a list of single device type
GET https://<host>:<post>/SKLM/rest/v1/deviceTypes?deviceListType=admin
OR
GET https://<host>:<post>/SKLM/rest/v1/deviceTypes/<deviceListType>
Content-Type: application/json
Accept : application/json
Authorization : SKLMAuth userAuthId=37ea1939-1374-4db7-84cd-14e399be2d20
Accept-Language : en
Success response
Status Code : 200 OK
Content-Language: en
{“admin”:
{"items":
    [{ ‘’name’’:‘’LTO001‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d20’’
    },
    { ‘’name’’:”DISK002‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d21’’
    }],"identifier":"name"}
}
Service request to get list of multiple device types
GET https://<host>:<post>/SKLM/rest/v1/deviceTypes?deviceListType=admin,step
Content-Type: application/json
Accept : application/json
Authorization : SKLMAuth userAuthId=37ea1939-1374-4db7-84cd-14e399be2d20
Accept-Language : en
Success response
Status Code : 200 OK
Content-Language: en
{“admin”:
{"items":
    [{ ‘’name’’:‘’LTO001‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d20’’
    },
    { ‘’name’’:”DISK002‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d21’’
    }],"identifier":"name"},
“step”:
{"items":
    [{‘’name’’:‘’LTO001‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d20’’
    },
    { ‘’name’’:”DISK002‘’,
    ‘’label’’:’’1374-4db7-84cd-14e399be2d21’’
    }],"identifier":"name"}
Error response
Status Code : 400 Bad Request
Content-Language: en
{"code" : "CTGKM6002E", "message" : "CTGKM6002E Bad Request: Invalid 
user authentication ID or invalid request format.“}