@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
109 lines • 4.75 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.Experience = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* Resource for managing an AWS Kendra Experience.
*
* ## Example Usage
*
* ### Basic Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const example = new aws.kendra.Experience("example", {
* indexId: exampleAwsKendraIndex.id,
* description: "My Kendra Experience",
* name: "example",
* roleArn: exampleAwsIamRole.arn,
* configuration: {
* contentSourceConfiguration: {
* directPutContent: true,
* faqIds: [exampleAwsKendraFaq.faqId],
* },
* userIdentityConfiguration: {
* identityAttributeName: "12345ec453-1546651e-79c4-4554-91fa-00b43ccfa245",
* },
* },
* });
* ```
*
* ## Import
*
* Using `pulumi import`, import Kendra Experience using the unique identifiers of the experience and index separated by a slash (`/`). For example:
*
* ```sh
* $ pulumi import aws:kendra/experience:Experience example 1045d08d-66ef-4882-b3ed-dfb7df183e90/b34dfdf7-1f2b-4704-9581-79e00296845f
* ```
*/
class Experience extends pulumi.CustomResource {
/**
* Get an existing Experience 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 Experience(name, state, Object.assign(Object.assign({}, opts), { id: id }));
}
/**
* Returns true if the given object is an instance of Experience. 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'] === Experience.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["arn"] = state ? state.arn : undefined;
resourceInputs["configuration"] = state ? state.configuration : undefined;
resourceInputs["description"] = state ? state.description : undefined;
resourceInputs["endpoints"] = state ? state.endpoints : undefined;
resourceInputs["experienceId"] = state ? state.experienceId : undefined;
resourceInputs["indexId"] = state ? state.indexId : undefined;
resourceInputs["name"] = state ? state.name : undefined;
resourceInputs["region"] = state ? state.region : undefined;
resourceInputs["roleArn"] = state ? state.roleArn : undefined;
resourceInputs["status"] = state ? state.status : undefined;
}
else {
const args = argsOrState;
if ((!args || args.indexId === undefined) && !opts.urn) {
throw new Error("Missing required property 'indexId'");
}
if ((!args || args.roleArn === undefined) && !opts.urn) {
throw new Error("Missing required property 'roleArn'");
}
resourceInputs["configuration"] = args ? args.configuration : undefined;
resourceInputs["description"] = args ? args.description : undefined;
resourceInputs["indexId"] = args ? args.indexId : undefined;
resourceInputs["name"] = args ? args.name : undefined;
resourceInputs["region"] = args ? args.region : undefined;
resourceInputs["roleArn"] = args ? args.roleArn : undefined;
resourceInputs["arn"] = undefined /*out*/;
resourceInputs["endpoints"] = undefined /*out*/;
resourceInputs["experienceId"] = undefined /*out*/;
resourceInputs["status"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(Experience.__pulumiType, name, resourceInputs, opts);
}
}
exports.Experience = Experience;
/** @internal */
Experience.__pulumiType = 'aws:kendra/experience:Experience';
//# sourceMappingURL=experience.js.map