Create an IAM Access Key

POST /access-key

This operation creates a new IAM Access Key, which can either be restricted to specific API operations or unrestricted. The corresponding secret is only available in the response returned by this operation, the caller must take care of storing it safely as there is no other way to retrieve it.

Body Required

Responses

  • 200 object

    200

    • name string

      IAM Access Key name

    • key string

      IAM Access Key

    • secret string

      IAM Access Key Secret

    • type string

      IAM Access Key type

      Values are restricted or unrestricted.

    • version string

      IAM Access Key version

      Values are v2 or v1.

    • tags array[string]

      IAM Access Key tags

    • operations array[string]

      IAM Access Key operations

    • resources array[object]

      Access key resource

POST /access-key
curl \
 -X POST https://api-ch-gva-2.exoscale.com/v2/access-key \
 -H "Content-Type: application/json" \
 -d '{"name":"string","tags":["string"],"operations":["string"],"resources":[{"domain":"partner","resource-type":"product","resource-name":"string"}]}'
Request example
{
  "name": "string",
  "tags": [
    "string"
  ],
  "operations": [
    "string"
  ],
  "resources": [
    {
      "domain": "partner",
      "resource-type": "product",
      "resource-name": "string"
    }
  ]
}
Response example (200)
{
  "name": "string",
  "key": "string",
  "secret": "string",
  "type": "restricted",
  "version": "v2",
  "tags": [
    "string"
  ],
  "operations": [
    "string"
  ],
  "resources": [
    {
      "domain": "partner",
      "resource-type": "product",
      "resource-name": "string"
    }
  ]
}