Interface AwsSdkCall
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
AwsSdkCall.Jsii$Proxy
Example:
AwsCustomResource awsCustom = AwsCustomResource.Builder.create(this, "aws-custom")
.onCreate(AwsSdkCall.builder()
.service("...")
.action("...")
.parameters(Map.of(
"text", "..."))
.physicalResourceId(PhysicalResourceId.of("..."))
.build())
.onUpdate(AwsSdkCall.builder()
.service("...")
.action("...")
.parameters(Map.of(
"text", "...",
"resourceId", new PhysicalResourceIdReference()))
.build())
.policy(AwsCustomResourcePolicy.fromSdkCalls(SdkCallsPolicyOptions.builder()
.resources(AwsCustomResourcePolicy.ANY_RESOURCE)
.build()))
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forAwsSdkCallstatic final classAn implementation forAwsSdkCall -
Method Summary
Modifier and TypeMethodDescriptionstatic AwsSdkCall.Builderbuilder()The service action to call.default StringAPI version to use for the service.default StringUsed for running the SDK calls in underlying lambda with a different role Can be used primarily for cross-account requests to for example connect hostedzone with a shared vpc.default StringThe regex pattern to use to catch API errors.default StringDeprecated.use outputPaths insteadRestrict the data returned by the custom resource to specific paths in the API response.default ObjectThe parameters for the service action.default PhysicalResourceIdThe physical resource id of the custom resource for this call.default StringThe region to send service requests to.The service to call.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getAction
The service action to call. -
getService
The service to call. -
getApiVersion
API version to use for the service.Default: - use latest available API version
-
getAssumedRoleArn
Used for running the SDK calls in underlying lambda with a different role Can be used primarily for cross-account requests to for example connect hostedzone with a shared vpc.Example for Route53 / associateVPCWithHostedZone
Default: - run without assuming role
-
getIgnoreErrorCodesMatching
The regex pattern to use to catch API errors.The
codeproperty of theErrorobject will be tested against this pattern. If there is a match an error will not be thrown.Default: - do not catch errors
-
getOutputPath
Deprecated.use outputPaths instead(deprecated) Restrict the data returned by the custom resource to a specific path in the API response.Use this to limit the data returned by the custom resource if working with API calls that could potentially result in custom response objects exceeding the hard limit of 4096 bytes.
Example for ECS / updateService: 'service.deploymentConfiguration.maximumPercent'
Default: - return all data
-
getOutputPaths
Restrict the data returned by the custom resource to specific paths in the API response.Use this to limit the data returned by the custom resource if working with API calls that could potentially result in custom response objects exceeding the hard limit of 4096 bytes.
Example for ECS / updateService: ['service.deploymentConfiguration.maximumPercent']
Default: - return all data
-
getParameters
The parameters for the service action.Default: - no parameters
-
getPhysicalResourceId
The physical resource id of the custom resource for this call.Mandatory for onCreate or onUpdate calls.
Default: - no physical resource id
-
getRegion
The region to send service requests to.Note: Cross-region operations are generally considered an anti-pattern. Consider first deploying a stack in that region.
Default: - the region where this custom resource is deployed
-
builder
- Returns:
- a
AwsSdkCall.BuilderofAwsSdkCall
-