Create Key REST Service
Use the Create Key REST Service to create one or more symmetric keys to encrypt or decrypt data.
- Operation
POST
- URL
- https://host:port/SKLM/rest/v1/keys
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 hostname 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. |
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. |
Request body
JSON object with the following specification:
JSON property name | Description |
---|---|
numOfKeys | Specify the number of keys to create. If you specify a value for the
alias parameter, also specify a value for this parameter. Default value is
1 . |
alias | Specify the key alias if aliasRange is not specified. You must also specify the value for numOfKeys. Specify the value for aliasRange if alias is not specified. |
aliasRange | Specify the aliasRange if alias is not specified. |
keyGroupUuid | Specify the UUID of the key group. |
usage | Required. Specify the device group. You can include the following values:
|
Response
Response Headers
Header name | Value and description |
---|---|
Status Code |
|
Content-Type | application/json |
Content-Language | Locale for the response message. |
Success response body
JSON object with the following specification:
JSON property name | Description |
---|---|
code | Returns the code that is specified by the status property. |
status | Returns the status to indicate whether the key group is marked for rollover. |
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 create a key
-
POST https://9.202.179.42:9443/SKLM/rest/v1/keys { "numOfKeys": "10", "alias": "abc", "usage": "LTO" }'