Apache CloudStack 4.23.0.0 Root Admin API Reference

registerUserKeys

Registers an API key pair (API and secret keys) for a user.

Request parameters

Parameter NameDescriptionRequired
idID of the user.true
descriptionAPI key pair description.false
enddateExpiration date of the API key pair. The recommended format is "yyyy-MM-dd'T'HH:mm:ssZ" (e.g.: "2023-01-01T12:00:00+0100"); however, the following formats are also accepted: "yyyy-MM-dd HH:mm:ss" (e.g.: "2023-01-01 12:00:00") and "yyyy-MM-dd" (e.g.: "2023-01-01" - if the time is not added, it will be interpreted as "23:59:59"). If the recommended format is not used, the date will be considered in the server timezone.false
nameAPI key pair name.false
rulesThe rules of the API key pair. If no rules are informed, defaults to allowing all account permissions. Otherwise, only the explicitly informed permissions for the key pair will be considered. Lower indexed rules take precedence over higher. Thus, in the following example: "rules[0].rule=deleteUserKeys rules[0].permission=deny rules[1].rule=*UserKey* rules[1].permission=allow", all rules matching the expression "*UserKeys*" will be allowed, except for "deleteUserKeys".false
startdateStart date of the API key pair. The recommended format is "yyyy-MM-dd'T'HH:mm:ssZ" (e.g.: "2023-01-01T12:00:00+0100"); however, the following formats are also accepted: "yyyy-MM-dd HH:mm:ss" (e.g.: "2023-01-01 12:00:00") and "yyyy-MM-dd" (e.g.: "2023-01-01" - if the time is not added, it will be interpreted as "00:00:00"). If the recommended format is not used, the date will be considered in the server timezone.false

Response Tags

Response NameDescription
idID of the API key pair.
accountidAccount ID.
accountnameAccount name.
accounttypeAccount type.
apikeyThe API key of the registered user.
createdAPI key pair creation timestamp.
descriptionAPI key pair description.
domainName of the domain which the account belongs to.
domainidID of the domain which the account belongs to.
domainpathPath of the domain which the account belongs to.
enddateAPI key pair expiration date.
nameName of the API key pair
permissionsPermissions of the API key pair.
roleidID of the role.
rolenameName of the role.
roletypeType of the role (Admin, ResourceAdmin, DomainAdmin, User).
secretkeyThe secret key of the registered user.
startdateAPI key pair start date.
stateState of the API key pair.
useridID of the user that owns the keypair.
usernameUsername of the keypair's owner.