cURL
curl --request POST \ --url https://api.ctrl-hub.com/v3/orgs/{orgId}/iam/service-accounts/{accountId}/keys \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "data": { "type": "service-account-keys" } }'
{ "data": { "type": "service-accounts", "id": "14b28316-9c20-8a7d-e85a-b62f29a29ac5", "attributes": { "client_secret": "5-wyyBa465q6FikrEqtm07LbSc", "enabled": true } } }
Creates a new key for service account
data.attributes.secret
To understand how to authenticate, see the auth docs
The body is of type object.
object
The response is of type object.