@Generated(value="jsii-pacmak/1.74.0 (build 6d08790)", date="2023-03-22T19:35:51.438Z") public class CfnApiKey extends CfnResource implements IInspectable
The AWS::AppSync::ApiKey
resource creates a unique key that you can distribute to clients who are executing GraphQL operations with AWS AppSync that require an API key.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.appsync.*; CfnApiKey cfnApiKey = CfnApiKey.Builder.create(this, "MyCfnApiKey") .apiId("apiId") // the properties below are optional .apiKeyId("apiKeyId") .description("description") .expires(123) .build();
Modifier and Type | Class and Description |
---|---|
static class |
CfnApiKey.Builder
A fluent builder for
CfnApiKey . |
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
IConstruct.Jsii$Default
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
Modifier | Constructor and Description |
---|---|
|
CfnApiKey(Construct scope,
java.lang.String id,
CfnApiKeyProps props)
Create a new `AWS::AppSync::ApiKey`.
|
protected |
CfnApiKey(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnApiKey(software.amazon.jsii.JsiiObjectRef objRef) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getApiId()
Unique AWS AppSync GraphQL API ID for this API key.
|
java.lang.String |
getApiKeyId()
The API key ID.
|
java.lang.String |
getAttrApiKey()
The API key.
|
java.lang.String |
getAttrArn()
The Amazon Resource Name (ARN) of the API key, such as `arn:aws:appsync:us-east-1:123456789012:apis/graphqlapiid/apikey/apikeya1bzhi` .
|
protected java.util.Map<java.lang.String,java.lang.Object> |
getCfnProperties() |
java.lang.String |
getDescription()
Unique description of your API key.
|
java.lang.Number |
getExpires()
The time after which the API key expires.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected java.util.Map<java.lang.String,java.lang.Object> |
renderProperties(java.util.Map<java.lang.String,java.lang.Object> props) |
void |
setApiId(java.lang.String value)
Unique AWS AppSync GraphQL API ID for this API key.
|
void |
setApiKeyId(java.lang.String value)
The API key ID.
|
void |
setDescription(java.lang.String value)
Unique description of your API key.
|
void |
setExpires(java.lang.Number value)
The time after which the API key expires.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validateProperties
getRef
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
public static final java.lang.String CFN_RESOURCE_TYPE_NAME
protected CfnApiKey(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnApiKey(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
public CfnApiKey(Construct scope, java.lang.String id, CfnApiKeyProps props)
scope
- - scope in which this resource is defined. This parameter is required.id
- - scoped id of the resource. This parameter is required.props
- - resource properties. This parameter is required.public void inspect(TreeInspector inspector)
inspect
in interface IInspectable
inspector
- - tree inspector to collect and process attributes. This parameter is required.protected java.util.Map<java.lang.String,java.lang.Object> renderProperties(java.util.Map<java.lang.String,java.lang.Object> props)
renderProperties
in class CfnResource
props
- This parameter is required.public java.lang.String getAttrApiKey()
public java.lang.String getAttrArn()
protected java.util.Map<java.lang.String,java.lang.Object> getCfnProperties()
getCfnProperties
in class CfnResource
public java.lang.String getApiId()
public void setApiId(java.lang.String value)
public java.lang.String getApiKeyId()
public void setApiKeyId(java.lang.String value)
public java.lang.String getDescription()
public void setDescription(java.lang.String value)
public java.lang.Number getExpires()
The date is represented as seconds since the epoch, rounded down to the nearest hour.
public void setExpires(java.lang.Number value)
The date is represented as seconds since the epoch, rounded down to the nearest hour.