Creates a key_pair with given parameters

Params

Param name Description
key_pair
required

Object containing information about the key_pair to be created


Value: Must be a Hash
pretty
optional

Return a pretty formatted response if true, Default is false


Value: Must be a Boolean
is_oem
optional

Generates key pair of child account if is_oem flag is true.


Value: Must be a Boolean
child_organisation_key
optional

Organisation key of child account where oem user wants to create key pair. Required field if is_oem is present.


Value: Must be a String

Examples

Request
  curl -X POST -H "Content-Type:application/json" -H "X-Auth-Token:WtUFnj8pvSxVnH9e_xkq7A" -d '{"key_pair":{"expiry_date":"09/09/2016","role_key":"517d8e4695"}}' https://api.datonis.io/api/v3/key_pairs

Response (returns details of the key_pair created)
{
  "key_pair": {
    "access_key": "abec9bb3d2e18c2c1dt4t792b3t73768bf7d68cd",
    "enabled": true,
    "expiry_date": "2016-09-08T18:30:00.000Z",
    "secret_key": "f2ddt21at5f56128a36t8t9949231acc89481f2f",
    "key_pair_key": "abec9bb3d2e18c2c1dt4t792b3t73768bf7d68cd",
    "created_at": 1446448242,
    "updated_at": 1446448242,
    "role_name": "Write Only",
    "role_key": "517d8e4695"
  }
}