@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
105 lines • 4.69 kB
JavaScript
;
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.InferenceProfile = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* Resource for managing an AWS Bedrock Inference Profile.
*
* ## Example Usage
*
* ### Basic Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const current = aws.getCallerIdentity({});
* const example = new aws.bedrock.InferenceProfile("example", {
* name: "Claude Sonnet for Project 123",
* description: "Profile with tag for cost allocation tracking",
* modelSource: {
* copyFrom: "arn:aws:bedrock:us-west-2::foundation-model/anthropic.claude-3-5-sonnet-20241022-v2:0",
* },
* tags: {
* ProjectID: "123",
* },
* });
* ```
*
* ## Import
*
* Using `pulumi import`, import Bedrock Inference Profile using the `name`. For example:
*
* ```sh
* $ pulumi import aws:bedrock/inferenceProfile:InferenceProfile example inference_profile-id-12345678
* ```
*/
class InferenceProfile extends pulumi.CustomResource {
/**
* Get an existing InferenceProfile resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name, id, state, opts) {
return new InferenceProfile(name, state, Object.assign(Object.assign({}, opts), { id: id }));
}
/**
* Returns true if the given object is an instance of InferenceProfile. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj) {
if (obj === undefined || obj === null) {
return false;
}
return obj['__pulumiType'] === InferenceProfile.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["arn"] = state ? state.arn : undefined;
resourceInputs["createdAt"] = state ? state.createdAt : undefined;
resourceInputs["description"] = state ? state.description : undefined;
resourceInputs["modelSource"] = state ? state.modelSource : undefined;
resourceInputs["models"] = state ? state.models : undefined;
resourceInputs["name"] = state ? state.name : undefined;
resourceInputs["region"] = state ? state.region : undefined;
resourceInputs["status"] = state ? state.status : undefined;
resourceInputs["tags"] = state ? state.tags : undefined;
resourceInputs["tagsAll"] = state ? state.tagsAll : undefined;
resourceInputs["timeouts"] = state ? state.timeouts : undefined;
resourceInputs["type"] = state ? state.type : undefined;
resourceInputs["updatedAt"] = state ? state.updatedAt : undefined;
}
else {
const args = argsOrState;
resourceInputs["description"] = args ? args.description : undefined;
resourceInputs["modelSource"] = args ? args.modelSource : undefined;
resourceInputs["name"] = args ? args.name : undefined;
resourceInputs["region"] = args ? args.region : undefined;
resourceInputs["tags"] = args ? args.tags : undefined;
resourceInputs["timeouts"] = args ? args.timeouts : undefined;
resourceInputs["arn"] = undefined /*out*/;
resourceInputs["createdAt"] = undefined /*out*/;
resourceInputs["models"] = undefined /*out*/;
resourceInputs["status"] = undefined /*out*/;
resourceInputs["tagsAll"] = undefined /*out*/;
resourceInputs["type"] = undefined /*out*/;
resourceInputs["updatedAt"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(InferenceProfile.__pulumiType, name, resourceInputs, opts);
}
}
exports.InferenceProfile = InferenceProfile;
/** @internal */
InferenceProfile.__pulumiType = 'aws:bedrock/inferenceProfile:InferenceProfile';
//# sourceMappingURL=inferenceProfile.js.map