Class AssetApiSchema
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.bedrockagentcore.ApiSchema
software.amazon.awscdk.services.bedrockagentcore.AssetApiSchema
- All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable
@Generated(value="jsii-pacmak/1.130.0 (build 048a5ee)",
date="2026-05-19T19:44:36.899Z")
@Stability(Stable)
public class AssetApiSchema
extends ApiSchema
API Schema from a local asset.
The asset is uploaded to an S3 staging bucket, then moved to its final location by CloudFormation during deployment.
Example:
Gateway gateway = Gateway.Builder.create(this, "MyGateway")
.gatewayName("my-gateway")
.build();
AssetApiSchema smithySchema = ApiSchema.fromLocalAsset(path.join(__dirname, "models", "smithy-model.json"));
smithySchema.bind(this);
// Create a gateway target with Smithy Model and OAuth
GatewayTarget target = GatewayTarget.forSmithy(this, "MySmithyTarget", GatewayTargetSmithyProps.builder()
.gatewayTargetName("my-smithy-target")
.description("Target for Smithy model integration")
.gateway(gateway)
.smithyModel(smithySchema)
.build());
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode -
Constructor Summary
ConstructorsModifierConstructorDescriptionAssetApiSchema(String path) AssetApiSchema(String path, AssetOptions options) protectedAssetApiSchema(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedAssetApiSchema(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionvoidbind(software.constructs.Construct scope) Binds this API schema to a construct scope.voidgrantPermissionsToRole(IRole role) Grant permissions to the role.Methods inherited from class software.amazon.awscdk.services.bedrockagentcore.ApiSchema
fromInline, fromLocalAsset, fromS3File, fromS3File, getBucketOwnerAccountId, getInlineSchema, getS3FileMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
AssetApiSchema
protected AssetApiSchema(software.amazon.jsii.JsiiObjectRef objRef) -
AssetApiSchema
protected AssetApiSchema(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
AssetApiSchema
- Parameters:
path- This parameter is required.options-
-
AssetApiSchema
- Parameters:
path- This parameter is required.
-
-
Method Details
-
bind
@Stability(Stable) public void bind(@NotNull software.constructs.Construct scope) Binds this API schema to a construct scope.This method initializes the S3 asset if it hasn't been initialized yet. Must be called before rendering the schema as CFN properties.
-
grantPermissionsToRole
Grant permissions to the role.- Specified by:
grantPermissionsToRolein classApiSchema- Parameters:
role- This parameter is required.
-