Skip to content
v2.277.0

SalesforceConfigurationProperty Struct ​

Provides the configuration information to connect to Salesforce as your data source.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_kendra as kendra } from 'aws-cdk-lib';
const salesforceConfigurationProperty: kendra.CfnDataSource.SalesforceConfigurationProperty = {
  secretArn: 'secretArn',
  serverUrl: 'serverUrl',

  // the properties below are optional
  chatterFeedConfiguration: {
    documentDataFieldName: 'documentDataFieldName',

    // the properties below are optional
    documentTitleFieldName: 'documentTitleFieldName',
    fieldMappings: [{
      dataSourceFieldName: 'dataSourceFieldName',
      indexFieldName: 'indexFieldName',

      // the properties below are optional
      dateFieldFormat: 'dateFieldFormat',
    }],
    includeFilterTypes: ['includeFilterTypes'],
  },
  crawlAttachments: false,
  excludeAttachmentFilePatterns: ['excludeAttachmentFilePatterns'],
  includeAttachmentFilePatterns: ['includeAttachmentFilePatterns'],
  knowledgeArticleConfiguration: {
    includedStates: ['includedStates'],

    // the properties below are optional
    customKnowledgeArticleTypeConfigurations: [{
      documentDataFieldName: 'documentDataFieldName',
      name: 'name',

      // the properties below are optional
      documentTitleFieldName: 'documentTitleFieldName',
      fieldMappings: [{
        dataSourceFieldName: 'dataSourceFieldName',
        indexFieldName: 'indexFieldName',

        // the properties below are optional
        dateFieldFormat: 'dateFieldFormat',
      }],
    }],
    standardKnowledgeArticleTypeConfiguration: {
      documentDataFieldName: 'documentDataFieldName',

      // the properties below are optional
      documentTitleFieldName: 'documentTitleFieldName',
      fieldMappings: [{
        dataSourceFieldName: 'dataSourceFieldName',
        indexFieldName: 'indexFieldName',

        // the properties below are optional
        dateFieldFormat: 'dateFieldFormat',
      }],
    },
  },
  standardObjectAttachmentConfiguration: {
    documentTitleFieldName: 'documentTitleFieldName',
    fieldMappings: [{
      dataSourceFieldName: 'dataSourceFieldName',
      indexFieldName: 'indexFieldName',

      // the properties below are optional
      dateFieldFormat: 'dateFieldFormat',
    }],
  },
  standardObjectConfigurations: [{
    documentDataFieldName: 'documentDataFieldName',
    name: 'name',

    // the properties below are optional
    documentTitleFieldName: 'documentTitleFieldName',
    fieldMappings: [{
      dataSourceFieldName: 'dataSourceFieldName',
      indexFieldName: 'indexFieldName',

      // the properties below are optional
      dateFieldFormat: 'dateFieldFormat',
    }],
  }],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_kendra as kendra

salesforce_configuration_property = kendra.CfnDataSource.SalesforceConfigurationProperty(
    secret_arn="secretArn",
    server_url="serverUrl",

    # the properties below are optional
    chatter_feed_configuration=kendra.CfnDataSource.SalesforceChatterFeedConfigurationProperty(
        document_data_field_name="documentDataFieldName",

        # the properties below are optional
        document_title_field_name="documentTitleFieldName",
        field_mappings=[kendra.CfnDataSource.DataSourceToIndexFieldMappingProperty(
            data_source_field_name="dataSourceFieldName",
            index_field_name="indexFieldName",

            # the properties below are optional
            date_field_format="dateFieldFormat"
        )],
        include_filter_types=["includeFilterTypes"]
    ),
    crawl_attachments=False,
    exclude_attachment_file_patterns=["excludeAttachmentFilePatterns"],
    include_attachment_file_patterns=["includeAttachmentFilePatterns"],
    knowledge_article_configuration=kendra.CfnDataSource.SalesforceKnowledgeArticleConfigurationProperty(
        included_states=["includedStates"],

        # the properties below are optional
        custom_knowledge_article_type_configurations=[kendra.CfnDataSource.SalesforceCustomKnowledgeArticleTypeConfigurationProperty(
            document_data_field_name="documentDataFieldName",
            name="name",

            # the properties below are optional
            document_title_field_name="documentTitleFieldName",
            field_mappings=[kendra.CfnDataSource.DataSourceToIndexFieldMappingProperty(
                data_source_field_name="dataSourceFieldName",
                index_field_name="indexFieldName",

                # the properties below are optional
                date_field_format="dateFieldFormat"
            )]
        )],
        standard_knowledge_article_type_configuration=kendra.CfnDataSource.SalesforceStandardKnowledgeArticleTypeConfigurationProperty(
            document_data_field_name="documentDataFieldName",

            # the properties below are optional
            document_title_field_name="documentTitleFieldName",
            field_mappings=[kendra.CfnDataSource.DataSourceToIndexFieldMappingProperty(
                data_source_field_name="dataSourceFieldName",
                index_field_name="indexFieldName",

                # the properties below are optional
                date_field_format="dateFieldFormat"
            )]
        )
    ),
    standard_object_attachment_configuration=kendra.CfnDataSource.SalesforceStandardObjectAttachmentConfigurationProperty(
        document_title_field_name="documentTitleFieldName",
        field_mappings=[kendra.CfnDataSource.DataSourceToIndexFieldMappingProperty(
            data_source_field_name="dataSourceFieldName",
            index_field_name="indexFieldName",

            # the properties below are optional
            date_field_format="dateFieldFormat"
        )]
    ),
    standard_object_configurations=[kendra.CfnDataSource.SalesforceStandardObjectConfigurationProperty(
        document_data_field_name="documentDataFieldName",
        name="name",

        # the properties below are optional
        document_title_field_name="documentTitleFieldName",
        field_mappings=[kendra.CfnDataSource.DataSourceToIndexFieldMappingProperty(
            data_source_field_name="dataSourceFieldName",
            index_field_name="indexFieldName",

            # the properties below are optional
            date_field_format="dateFieldFormat"
        )]
    )]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.kendra.*;

SalesforceConfigurationProperty salesforceConfigurationProperty = SalesforceConfigurationProperty.builder()
        .secretArn("secretArn")
        .serverUrl("serverUrl")

        // the properties below are optional
        .chatterFeedConfiguration(SalesforceChatterFeedConfigurationProperty.builder()
                .documentDataFieldName("documentDataFieldName")

                // the properties below are optional
                .documentTitleFieldName("documentTitleFieldName")
                .fieldMappings(List.of(DataSourceToIndexFieldMappingProperty.builder()
                        .dataSourceFieldName("dataSourceFieldName")
                        .indexFieldName("indexFieldName")

                        // the properties below are optional
                        .dateFieldFormat("dateFieldFormat")
                        .build()))
                .includeFilterTypes(List.of("includeFilterTypes"))
                .build())
        .crawlAttachments(false)
        .excludeAttachmentFilePatterns(List.of("excludeAttachmentFilePatterns"))
        .includeAttachmentFilePatterns(List.of("includeAttachmentFilePatterns"))
        .knowledgeArticleConfiguration(SalesforceKnowledgeArticleConfigurationProperty.builder()
                .includedStates(List.of("includedStates"))

                // the properties below are optional
                .customKnowledgeArticleTypeConfigurations(List.of(SalesforceCustomKnowledgeArticleTypeConfigurationProperty.builder()
                        .documentDataFieldName("documentDataFieldName")
                        .name("name")

                        // the properties below are optional
                        .documentTitleFieldName("documentTitleFieldName")
                        .fieldMappings(List.of(DataSourceToIndexFieldMappingProperty.builder()
                                .dataSourceFieldName("dataSourceFieldName")
                                .indexFieldName("indexFieldName")

                                // the properties below are optional
                                .dateFieldFormat("dateFieldFormat")
                                .build()))
                        .build()))
                .standardKnowledgeArticleTypeConfiguration(SalesforceStandardKnowledgeArticleTypeConfigurationProperty.builder()
                        .documentDataFieldName("documentDataFieldName")

                        // the properties below are optional
                        .documentTitleFieldName("documentTitleFieldName")
                        .fieldMappings(List.of(DataSourceToIndexFieldMappingProperty.builder()
                                .dataSourceFieldName("dataSourceFieldName")
                                .indexFieldName("indexFieldName")

                                // the properties below are optional
                                .dateFieldFormat("dateFieldFormat")
                                .build()))
                        .build())
                .build())
        .standardObjectAttachmentConfiguration(SalesforceStandardObjectAttachmentConfigurationProperty.builder()
                .documentTitleFieldName("documentTitleFieldName")
                .fieldMappings(List.of(DataSourceToIndexFieldMappingProperty.builder()
                        .dataSourceFieldName("dataSourceFieldName")
                        .indexFieldName("indexFieldName")

                        // the properties below are optional
                        .dateFieldFormat("dateFieldFormat")
                        .build()))
                .build())
        .standardObjectConfigurations(List.of(SalesforceStandardObjectConfigurationProperty.builder()
                .documentDataFieldName("documentDataFieldName")
                .name("name")

                // the properties below are optional
                .documentTitleFieldName("documentTitleFieldName")
                .fieldMappings(List.of(DataSourceToIndexFieldMappingProperty.builder()
                        .dataSourceFieldName("dataSourceFieldName")
                        .indexFieldName("indexFieldName")

                        // the properties below are optional
                        .dateFieldFormat("dateFieldFormat")
                        .build()))
                .build()))
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Kendra;

var salesforceConfigurationProperty = new SalesforceConfigurationProperty {
    SecretArn = "secretArn",
    ServerUrl = "serverUrl",

    // the properties below are optional
    ChatterFeedConfiguration = new SalesforceChatterFeedConfigurationProperty {
        DocumentDataFieldName = "documentDataFieldName",

        // the properties below are optional
        DocumentTitleFieldName = "documentTitleFieldName",
        FieldMappings = new [] { new DataSourceToIndexFieldMappingProperty {
            DataSourceFieldName = "dataSourceFieldName",
            IndexFieldName = "indexFieldName",

            // the properties below are optional
            DateFieldFormat = "dateFieldFormat"
        } },
        IncludeFilterTypes = new [] { "includeFilterTypes" }
    },
    CrawlAttachments = false,
    ExcludeAttachmentFilePatterns = new [] { "excludeAttachmentFilePatterns" },
    IncludeAttachmentFilePatterns = new [] { "includeAttachmentFilePatterns" },
    KnowledgeArticleConfiguration = new SalesforceKnowledgeArticleConfigurationProperty {
        IncludedStates = new [] { "includedStates" },

        // the properties below are optional
        CustomKnowledgeArticleTypeConfigurations = new [] { new SalesforceCustomKnowledgeArticleTypeConfigurationProperty {
            DocumentDataFieldName = "documentDataFieldName",
            Name = "name",

            // the properties below are optional
            DocumentTitleFieldName = "documentTitleFieldName",
            FieldMappings = new [] { new DataSourceToIndexFieldMappingProperty {
                DataSourceFieldName = "dataSourceFieldName",
                IndexFieldName = "indexFieldName",

                // the properties below are optional
                DateFieldFormat = "dateFieldFormat"
            } }
        } },
        StandardKnowledgeArticleTypeConfiguration = new SalesforceStandardKnowledgeArticleTypeConfigurationProperty {
            DocumentDataFieldName = "documentDataFieldName",

            // the properties below are optional
            DocumentTitleFieldName = "documentTitleFieldName",
            FieldMappings = new [] { new DataSourceToIndexFieldMappingProperty {
                DataSourceFieldName = "dataSourceFieldName",
                IndexFieldName = "indexFieldName",

                // the properties below are optional
                DateFieldFormat = "dateFieldFormat"
            } }
        }
    },
    StandardObjectAttachmentConfiguration = new SalesforceStandardObjectAttachmentConfigurationProperty {
        DocumentTitleFieldName = "documentTitleFieldName",
        FieldMappings = new [] { new DataSourceToIndexFieldMappingProperty {
            DataSourceFieldName = "dataSourceFieldName",
            IndexFieldName = "indexFieldName",

            // the properties below are optional
            DateFieldFormat = "dateFieldFormat"
        } }
    },
    StandardObjectConfigurations = new [] { new SalesforceStandardObjectConfigurationProperty {
        DocumentDataFieldName = "documentDataFieldName",
        Name = "name",

        // the properties below are optional
        DocumentTitleFieldName = "documentTitleFieldName",
        FieldMappings = new [] { new DataSourceToIndexFieldMappingProperty {
            DataSourceFieldName = "dataSourceFieldName",
            IndexFieldName = "indexFieldName",

            // the properties below are optional
            DateFieldFormat = "dateFieldFormat"
        } }
    } }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

salesforceConfigurationProperty := &SalesforceConfigurationProperty{
	SecretArn: jsii.String("secretArn"),
	ServerUrl: jsii.String("serverUrl"),

	// the properties below are optional
	ChatterFeedConfiguration: &SalesforceChatterFeedConfigurationProperty{
		DocumentDataFieldName: jsii.String("documentDataFieldName"),

		// the properties below are optional
		DocumentTitleFieldName: jsii.String("documentTitleFieldName"),
		FieldMappings: []interface{}{
			&DataSourceToIndexFieldMappingProperty{
				DataSourceFieldName: jsii.String("dataSourceFieldName"),
				IndexFieldName: jsii.String("indexFieldName"),

				// the properties below are optional
				DateFieldFormat: jsii.String("dateFieldFormat"),
			},
		},
		IncludeFilterTypes: []*string{
			jsii.String("includeFilterTypes"),
		},
	},
	CrawlAttachments: jsii.Boolean(false),
	ExcludeAttachmentFilePatterns: []*string{
		jsii.String("excludeAttachmentFilePatterns"),
	},
	IncludeAttachmentFilePatterns: []*string{
		jsii.String("includeAttachmentFilePatterns"),
	},
	KnowledgeArticleConfiguration: &SalesforceKnowledgeArticleConfigurationProperty{
		IncludedStates: []*string{
			jsii.String("includedStates"),
		},

		// the properties below are optional
		CustomKnowledgeArticleTypeConfigurations: []interface{}{
			&SalesforceCustomKnowledgeArticleTypeConfigurationProperty{
				DocumentDataFieldName: jsii.String("documentDataFieldName"),
				Name: jsii.String("name"),

				// the properties below are optional
				DocumentTitleFieldName: jsii.String("documentTitleFieldName"),
				FieldMappings: []interface{}{
					&DataSourceToIndexFieldMappingProperty{
						DataSourceFieldName: jsii.String("dataSourceFieldName"),
						IndexFieldName: jsii.String("indexFieldName"),

						// the properties below are optional
						DateFieldFormat: jsii.String("dateFieldFormat"),
					},
				},
			},
		},
		StandardKnowledgeArticleTypeConfiguration: &SalesforceStandardKnowledgeArticleTypeConfigurationProperty{
			DocumentDataFieldName: jsii.String("documentDataFieldName"),

			// the properties below are optional
			DocumentTitleFieldName: jsii.String("documentTitleFieldName"),
			FieldMappings: []interface{}{
				&DataSourceToIndexFieldMappingProperty{
					DataSourceFieldName: jsii.String("dataSourceFieldName"),
					IndexFieldName: jsii.String("indexFieldName"),

					// the properties below are optional
					DateFieldFormat: jsii.String("dateFieldFormat"),
				},
			},
		},
	},
	StandardObjectAttachmentConfiguration: &SalesforceStandardObjectAttachmentConfigurationProperty{
		DocumentTitleFieldName: jsii.String("documentTitleFieldName"),
		FieldMappings: []interface{}{
			&DataSourceToIndexFieldMappingProperty{
				DataSourceFieldName: jsii.String("dataSourceFieldName"),
				IndexFieldName: jsii.String("indexFieldName"),

				// the properties below are optional
				DateFieldFormat: jsii.String("dateFieldFormat"),
			},
		},
	},
	StandardObjectConfigurations: []interface{}{
		&SalesforceStandardObjectConfigurationProperty{
			DocumentDataFieldName: jsii.String("documentDataFieldName"),
			Name: jsii.String("name"),

			// the properties below are optional
			DocumentTitleFieldName: jsii.String("documentTitleFieldName"),
			FieldMappings: []interface{}{
				&DataSourceToIndexFieldMappingProperty{
					DataSourceFieldName: jsii.String("dataSourceFieldName"),
					IndexFieldName: jsii.String("indexFieldName"),

					// the properties below are optional
					DateFieldFormat: jsii.String("dateFieldFormat"),
				},
			},
		},
	},
}

Properties ​

chatterFeedConfigurationoptionalIResolvable | CfnDataSource.SalesforceChatterFeedConfigurationPropertychatter_feed_configurationoptionaltyping.Union[IResolvable, SalesforceChatterFeedConfigurationProperty]chatterFeedConfigurationoptionalIResolvableChatterFeedConfigurationoptionalIResolvableChatterFeedConfigurationoptionalinterface{} #
Configuration information for Salesforce chatter feeds.
crawlAttachmentsoptionalboolean | IResolvablecrawl_attachmentsoptionaltyping.Union[bool, IResolvable]crawlAttachmentsoptionalBooleanCrawlAttachmentsoptionalboolCrawlAttachmentsoptionalinterface{} #
Indicates whether Amazon Kendra should index attachments to Salesforce objects.
excludeAttachmentFilePatternsoptionalstring[]exclude_attachment_file_patternsoptionaltyping.List[str]excludeAttachmentFilePatternsoptionalList<String>ExcludeAttachmentFilePatternsoptionalstring[]ExcludeAttachmentFilePatternsoptional*[]*string #
A list of regular expression patterns to exclude certain documents in your Salesforce.
notes

Documents that match the patterns are excluded from the index. Documents that don't match the patterns are included in the index. If a document matches both an inclusion and exclusion pattern, the exclusion pattern takes precedence and the document isn't included in the index.

The pattern is applied to the name of the attached file.

includeAttachmentFilePatternsoptionalstring[]include_attachment_file_patternsoptionaltyping.List[str]includeAttachmentFilePatternsoptionalList<String>IncludeAttachmentFilePatternsoptionalstring[]IncludeAttachmentFilePatternsoptional*[]*string #
A list of regular expression patterns to include certain documents in your Salesforce.
notes

Documents that match the patterns are included in the index. Documents that don't match the patterns are excluded from the index. If a document matches both an inclusion and exclusion pattern, the exclusion pattern takes precedence and the document isn't included in the index.

The pattern is applied to the name of the attached file.

knowledgeArticleConfigurationoptionalIResolvable | CfnDataSource.SalesforceKnowledgeArticleConfigurationPropertyknowledge_article_configurationoptionaltyping.Union[IResolvable, SalesforceKnowledgeArticleConfigurationProperty]knowledgeArticleConfigurationoptionalIResolvableKnowledgeArticleConfigurationoptionalIResolvableKnowledgeArticleConfigurationoptionalinterface{} #
Configuration information for the knowledge article types that Amazon Kendra indexes.

Amazon Kendra indexes standard knowledge articles and the standard fields of knowledge articles, or the custom fields of custom knowledge articles, but not both.

secretArnstringsecret_arnstrsecretArnStringSecretArnstringSecretArn*string required #
The Amazon Resource Name (ARN) of an AWS Secrets Manager secret that contains the key/value pairs required to connect to your Salesforce instance.
notes

The secret must contain a JSON structure with the following keys:

  • authenticationUrl - The OAUTH endpoint that Amazon Kendra connects to get an OAUTH token.
  • consumerKey - The application public key generated when you created your Salesforce application.
  • consumerSecret - The application private key generated when you created your Salesforce application.
  • password - The password associated with the user logging in to the Salesforce instance.
  • securityToken - The token associated with the user logging in to the Salesforce instance.
  • username - The user name of the user logging in to the Salesforce instance.
serverUrlstringserver_urlstrserverUrlStringServerUrlstringServerUrl*string required #
The instance URL for the Salesforce site that you want to index.
standardObjectAttachmentConfigurationoptionalIResolvable | CfnDataSource.SalesforceStandardObjectAttachmentConfigurationPropertystandard_object_attachment_configurationoptionaltyping.Union[IResolvable, SalesforceStandardObjectAttachmentConfigurationProperty]standardObjectAttachmentConfigurationoptionalIResolvableStandardObjectAttachmentConfigurationoptionalIResolvableStandardObjectAttachmentConfigurationoptionalinterface{} #
Configuration information for processing attachments to Salesforce standard objects.
standardObjectConfigurationsoptionalIResolvable | IResolvable | CfnDataSource.SalesforceStandardObjectConfigurationProperty[]standard_object_configurationsoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, SalesforceStandardObjectConfigurationProperty]]]standardObjectConfigurationsoptionalIResolvableStandardObjectConfigurationsoptionalIResolvableStandardObjectConfigurationsoptionalinterface{} #
Configuration of the Salesforce standard objects that Amazon Kendra indexes.