Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Skip to main content
A builder class for creating and importing symmetric keys. This class provides methods to configure key properties and generate or import symmetric keys.

Extends

  • BaseCryptoClass

Accessors

algorithm

Set Signature

set algorithm(algorithm): void Set the algorithm this key will be used with. Defaults to AES-256.
Throws
InvalidArgumentError If the algorithm is not supported.
Parameters
algorithm
SymmetricAlgorithm The symmetric algorithm to use.
Returns
void

bits

Set Signature

set bits(bits): void Set the number of bits for the key. Defaults to 256 for AES.
Parameters
bits
number The number of bits for the key.
Returns
void
Last modified on October 2, 2025