REST API
4.0.0
REST API for SafeNet Network HSMs
|
Performs the action on the object.
The serial number of the HSM of interest
Use: Required
JSON Schema:
Object type: string
The identifier of the partition of interest
Use: Required
JSON Schema:
Object type: string
The identifier of the object of interest
Use: Required
JSON Schema:
Object type: string
The identifier of the object action to be performed
Use: Required
JSON Schema:
Object type: string
The reference to be assigned to a backup device
Use: Required
JSON Schema:
Object type: string
A list of identifier to objects to be backed up or objects restored
Use: Required
JSON Schema:
Array id: Object type: string description: id is a reference to an object. A null list ([]) means backup or restore all objects.
Success, response returned
JSON Schema:
Response returned is specific to the object action performed.
Success, no response returned
"Location" is the URL to the task spawned to perform the requested action on the partition object.
Unexpected error
HSM, partition, or action does not exist.
POST https://1.2.3.4:8443/api/lunasa/hsms/154704/partitions/273087011507/objects/actions/backup {"ids":["31","22","35","36"], "name":"targetBackupName"} POST https://1.2.3.4:8443/api/lunasa/hsms/154704/partitions/273087011507/objects/actions/restore {"ids":["0","1","2"]}
{'Access-Control-Allow-Origin': '*', 'Content-Type': 'application/json', 'Location': '/tasks/13', 'Content-Length': '712', 'Access-Control-Allow-Credentials': 'true'} {}
In this example, do GET on '/tasks/13/response' to get the results of the task, assuming the action was 'restore':
{ "ids": [ "19", "23", "24" ] }
The 'restore' action returns the new object handles.