Amazon KMS Kms Key Rotation API

The Kms Key Rotation API from Amazon KMS — 3 operation(s) for kms key rotation.

Business capability
Cybersecurity Management BC-620

Operations 3

POST /#DisableKeyRotation Disable Key Rotation #
POST /#EnableKeyRotation Enable Key Rotation #
POST /#ListKeyRotations List Key Rotations #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/amazon-kms:amazon-kms-key-rotation-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

amazon-kms-key-rotation-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: AWS Key Management Service Key Rotation API
  version: '2014-11-01'
  description: Generated from AWS's published Smithy model for AWS Key Management Service. 3 operation(s).
  contact:
    name: Amazon Web Services
    url: https://aws.amazon.com/contact-us/
  license:
    name: Apache 2.0
    identifier: Apache-2.0
    url: https://github.com/aws/api-models-aws/blob/main/LICENSE
servers:
- url: https://kms.{region}.amazonaws.com
  variables:
    region:
      default: us-east-1
security:
- sigv4: []
tags:
- name: Key Rotation
paths:
  /#DisableKeyRotation:
    post:
      operationId: DisableKeyRotation
      summary: Disable Key Rotation
      description: 'Disables automatic rotation of the key material of the specified symmetric encryption KMS key. Automatic key rotation is supported only on symmetric encryption KMS keys. You cannot enable automatic rotation of asymmetric KMS keys, HMAC KMS keys, KMS keys with imported key material, or KMS keys in a custom key store. To enable or disable automatic rotation of a set of related multi-Region keys, set the property on the primary key. You can enable (EnableKeyRotation) and disable automatic rotation of the key material in customer managed KMS keys. Key material rotation of Amazon Web Services managed KMS keys is not configurable. KMS always rotates the key material for every year. Rotation of Amazon Web Services owned KMS keys varies. In May 2022, KMS changed the rotation schedule for Amazon Web Services managed keys from every three years to every year. For details, see EnableKeyRotation. The KMS key that you use for this operation must be in a compatible key state. For details, see Key states of KMS keys in the Key Management Service Developer Guide. Cross-account use: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account. Required permissions:'
      responses:
        '200':
          description: Success
          content:
            application/x-amz-json-1.1:
              schema:
                type: string
        '503':
          description: DependencyTimeoutException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/DependencyTimeoutException'
        '409':
          description: DisabledException; KMSInvalidStateException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/DisabledException'
        '400':
          description: InvalidArnException; UnsupportedOperationException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/InvalidArnException'
        '500':
          description: KMSInternalException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/KMSInternalException'
        '404':
          description: NotFoundException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/NotFoundException'
      parameters:
      - name: X-Amz-Target
        in: header
        required: true
        schema:
          type: string
          enum:
          - TrentService.DisableKeyRotation
      requestBody:
        required: true
        content:
          application/x-amz-json-1.1:
            schema:
              $ref: '#/components/schemas/DisableKeyRotationRequest'
            example:
              KeyId: 1234abcd-12ab-34cd-56ef-1234567890ab
      tags:
      - Key Rotation
  /#EnableKeyRotation:
    post:
      operationId: EnableKeyRotation
      summary: Enable Key Rotation
      description: Enables automatic rotation of the key material of the specified symmetric encryption KMS key. By default, when you enable automatic rotation of a customer managed KMS key, KMS rotates the key material of the KMS key one year (approximately 365 days) from the enable date and every year thereafter. You can use the optional RotationPeriodInDays parameter to specify a custom rotation period when you enable key rotation, or you can use RotationPeriodInDays to modify the rotation period of a key that you previously enabled automatic key rotation on. You can monitor rotation of the key material for your KMS keys in CloudTrail and Amazon CloudWatch. To disable rotation of the key material in a customer managed KMS key, use the DisableKeyRotation operation. You can use the GetKeyRotationStatus operation to identify any in progress rotations. You can use the ListKeyRotations operation to view the details of completed rotations. Automatic key rotation is supported only on symmetric encryption KMS keys. You cannot enable automatic rotation of asymmetric KMS keys, HMAC KMS keys, KMS keys with imported key material, or KMS keys in a custom key store. To enable or disable automatic rotation of a
      responses:
        '200':
          description: Success
          content:
            application/x-amz-json-1.1:
              schema:
                type: string
        '503':
          description: DependencyTimeoutException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/DependencyTimeoutException'
        '409':
          description: DisabledException; KMSInvalidStateException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/DisabledException'
        '400':
          description: InvalidArnException; UnsupportedOperationException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/InvalidArnException'
        '500':
          description: KMSInternalException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/KMSInternalException'
        '404':
          description: NotFoundException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/NotFoundException'
      parameters:
      - name: X-Amz-Target
        in: header
        required: true
        schema:
          type: string
          enum:
          - TrentService.EnableKeyRotation
      requestBody:
        required: true
        content:
          application/x-amz-json-1.1:
            schema:
              $ref: '#/components/schemas/EnableKeyRotationRequest'
            example:
              KeyId: 1234abcd-12ab-34cd-56ef-1234567890ab
              RotationPeriodInDays: 365
      tags:
      - Key Rotation
  /#ListKeyRotations:
    post:
      operationId: ListKeyRotations
      summary: List Key Rotations
      description: 'Returns information about the key materials associated with the specified KMS key. You can use the optional IncludeKeyMaterial parameter to control which key materials are included in the response. You must specify the KMS key in all requests. You can refine the key rotations list by limiting the number of rotations returned. For detailed information about automatic and on-demand key rotations, see Rotate KMS keys in the Key Management Service Developer Guide. Cross-account use: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account. Required permissions: kms:ListKeyRotations (key policy) Related operations: EnableKeyRotation DeleteImportedKeyMaterial DisableKeyRotation GetKeyRotationStatus ImportKeyMaterial RotateKeyOnDemand Eventual consistency: The KMS API follows an eventual consistency model. For more information, see KMS eventual consistency.'
      responses:
        '200':
          description: Success
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/ListKeyRotationsResponse'
        '400':
          description: InvalidArnException; InvalidMarkerException; UnsupportedOperationException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/InvalidArnException'
        '500':
          description: KMSInternalException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/KMSInternalException'
        '409':
          description: KMSInvalidStateException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/KMSInvalidStateException'
        '404':
          description: NotFoundException
          content:
            application/x-amz-json-1.1:
              schema:
                $ref: '#/components/schemas/NotFoundException'
      parameters:
      - name: X-Amz-Target
        in: header
        required: true
        schema:
          type: string
          enum:
          - TrentService.ListKeyRotations
      requestBody:
        required: true
        content:
          application/x-amz-json-1.1:
            schema:
              $ref: '#/components/schemas/ListKeyRotationsRequest'
      tags:
      - Key Rotation
components:
  schemas:
    ListKeyRotationsResponse:
      type: object
      properties:
        Rotations:
          type: array
          items:
            $ref: '#/components/schemas/RotationsListEntry'
          description: A list of completed key material rotations. When the optional input parameter IncludeKeyMaterial is specified with a value of ALL_KEY_MATERIAL, this list includes the first key material and any imported key material pending rotation.
        NextMarker:
          type: string
          description: When Truncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent request.
        Truncated:
          type: boolean
          description: A flag that indicates whether there are more items in the list. When this value is true, the list in this response is truncated. To get more items, pass the value of the NextMarker element in this response to the Marker parameter in a subsequent request.
    NotFoundException:
      type: object
      properties:
        message:
          type: string
    ListKeyRotationsRequest:
      type: object
      properties:
        KeyId:
          type: string
          description: 'Gets the key rotations for the specified KMS key. Specify the key ID or key ARN of the KMS key. For example: Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.'
        IncludeKeyMaterial:
          type: string
          enum:
          - ALL_KEY_MATERIAL
          - ROTATIONS_ONLY
          description: Use this optional parameter to control which key materials associated with this key are listed in the response. The default value of this parameter is ROTATIONS_ONLY. If you omit this parameter, KMS returns information on the key materials created by automatic or on-demand key rotation. When you specify a value of ALL_KEY_MATERIAL, KMS adds the first key material and any imported key material pending rotation to the response. This parameter can only be used with KMS keys that support automatic or on-demand key rotation.
        Limit:
          type: integer
          description: Use this parameter to specify the maximum number of items to return. When this value is present, KMS does not return more than the specified number of items, but it might return fewer. This value is optional. If you include a value, it must be between 1 and 1000, inclusive. If you do not include a value, it defaults to 100.
        Marker:
          type: string
          description: Use this parameter in a subsequent request after you receive a response with truncated results. Set it to the value of NextMarker from the truncated response you just received.
      required:
      - KeyId
    DisableKeyRotationRequest:
      type: object
      properties:
        KeyId:
          type: string
          description: 'Identifies a symmetric encryption KMS key. You cannot enable or disable automatic rotation of asymmetric KMS keys, HMAC KMS keys, KMS keys with imported key material, or KMS keys in a custom key store. Specify the key ID or key ARN of the KMS key. For example: Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.'
      required:
      - KeyId
    EnableKeyRotationRequest:
      type: object
      properties:
        KeyId:
          type: string
          description: 'Identifies a symmetric encryption KMS key. You cannot enable automatic rotation of asymmetric KMS keys, HMAC KMS keys, KMS keys with imported key material, or KMS keys in a custom key store. To enable or disable automatic rotation of a set of related multi-Region keys, set the property on the primary key. Specify the key ID or key ARN of the KMS key. For example: Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.'
        RotationPeriodInDays:
          type: integer
          description: Use this parameter to specify a custom period of time between each rotation date. If no value is specified, the default value is 365 days. The rotation period defines the number of days after you enable automatic key rotation that KMS will rotate your key material, and the number of days between each automatic rotation thereafter. You can use the kms:RotationPeriodInDays condition key to further constrain the values that principals can specify in the RotationPeriodInDays parameter.
      required:
      - KeyId
    KMSInvalidStateException:
      type: object
      properties:
        message:
          type: string
    DisabledException:
      type: object
      properties:
        message:
          type: string
    RotationsListEntry:
      type: object
      properties:
        KeyId:
          type: string
          description: Unique identifier of the key.
        KeyMaterialId:
          type: string
          description: Unique identifier of the key material.
        KeyMaterialDescription:
          type: string
          description: User-specified description of the key material. This field is only present for symmetric encryption KMS keys with EXTERNAL origin.
        ImportState:
          type: string
          enum:
          - IMPORTED
          - PENDING_IMPORT
          description: 'Indicates if the key material is currently imported into KMS. It has two possible values: IMPORTED or PENDING_IMPORT. This field is only present for symmetric encryption KMS keys with EXTERNAL origin.'
        KeyMaterialState:
          type: string
          enum:
          - NON_CURRENT
          - CURRENT
          - PENDING_ROTATION
          - PENDING_MULTI_REGION_IMPORT_AND_ROTATION
          description: 'There are four possible values for this field: CURRENT, NON_CURRENT, PENDING_MULTI_REGION_IMPORT_AND_ROTATION and PENDING_ROTATION. KMS uses CURRENT key material for both encryption and decryption and NON_CURRENT key material only for decryption. PENDING_ROTATION identifies key material that has been imported for on-demand key rotation but the rotation hasn''t completed. The key material state PENDING_MULTI_REGION_IMPORT_AND_ROTATION is unique to multi-region, symmetric encryption keys with imported key material. It indicates key material that has been imported into the primary Region key but n'
        ExpirationModel:
          type: string
          enum:
          - KEY_MATERIAL_EXPIRES
          - KEY_MATERIAL_DOES_NOT_EXPIRE
          description: 'Indicates if the key material is configured to automatically expire. There are two possible values for this field: KEY_MATERIAL_EXPIRES and KEY_MATERIAL_DOES_NOT_EXPIRE. For any key material that expires, the expiration date and time is indicated in ValidTo. This field is only present for symmetric encryption KMS keys with EXTERNAL origin.'
        ValidTo:
          type: string
          format: date-time
          description: Date and time at which the key material expires. This field is only present for symmetric encryption KMS keys with EXTERNAL origin in rotation list entries with an ExpirationModel value of KEY_MATERIAL_EXPIRES.
        RotationDate:
          type: string
          format: date-time
          description: Date and time that the key material rotation completed. Formatted as Unix time. This field is not present for the first key material or an imported key material in PENDING_ROTATION state.
        RotationType:
          type: string
          enum:
          - AUTOMATIC
          - ON_DEMAND
          description: Identifies whether the key material rotation was a scheduled automatic rotation or an on-demand rotation. This field is not present for the first key material or an imported key material in PENDING_ROTATION state.
    KMSInternalException:
      type: object
      properties:
        message:
          type: string
    DependencyTimeoutException:
      type: object
      properties:
        message:
          type: string
    InvalidArnException:
      type: object
      properties:
        message:
          type: string
  securitySchemes:
    sigv4:
      type: apiKey
      in: header
      name: Authorization
      description: AWS Signature Version 4. The Authorization header carries an AWS4-HMAC-SHA256 signature over the canonical request, with X-Amz-Date (and X-Amz-Security-Token for temporary credentials). Not a bearer token.
      x-aws-sigv4:
        signingName: kms
x-provenance:
  method: harvested
  publisher: Amazon Web Services
  source: https://raw.githubusercontent.com/aws/api-models-aws/582e55931c45b944739742a2c1620b6026dd2d13/models/kms/service/2014-11-01/kms-2014-11-01.json
  note: converted by smithy-to-openapi.py from AWS's Smithy model (roadmap#1001)