You are viewing documentation for version 2 of the AWS SDK for Ruby. Version 3 documentation can be found here.

Class: Aws::Kendra::Types::CreateDataSourceRequest

Inherits:
Struct
  • Object
show all
Defined in:
(unknown)

Overview

Note:

When passing CreateDataSourceRequest as input to an Aws::Client method, you can use a vanilla Hash:

{
  name: "DataSourceName", # required
  index_id: "IndexId", # required
  type: "S3", # required, accepts S3, SHAREPOINT, DATABASE, SALESFORCE, ONEDRIVE, SERVICENOW, CUSTOM, CONFLUENCE
  configuration: {
    s3_configuration: {
      bucket_name: "S3BucketName", # required
      inclusion_prefixes: ["DataSourceInclusionsExclusionsStringsMember"],
      inclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      exclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      documents_metadata_configuration: {
        s3_prefix: "S3ObjectKey",
      },
      access_control_list_configuration: {
        key_path: "S3ObjectKey",
      },
    },
    share_point_configuration: {
      share_point_version: "SHAREPOINT_ONLINE", # required, accepts SHAREPOINT_ONLINE
      urls: ["Url"], # required
      secret_arn: "SecretArn", # required
      crawl_attachments: false,
      use_change_log: false,
      inclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      exclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      vpc_configuration: {
        subnet_ids: ["SubnetId"], # required
        security_group_ids: ["VpcSecurityGroupId"], # required
      },
      field_mappings: [
        {
          data_source_field_name: "DataSourceFieldName", # required
          date_field_format: "DataSourceDateFieldFormat",
          index_field_name: "IndexFieldName", # required
        },
      ],
      document_title_field_name: "DataSourceFieldName",
      disable_local_groups: false,
    },
    database_configuration: {
      database_engine_type: "RDS_AURORA_MYSQL", # required, accepts RDS_AURORA_MYSQL, RDS_AURORA_POSTGRESQL, RDS_MYSQL, RDS_POSTGRESQL
      connection_configuration: { # required
        database_host: "DatabaseHost", # required
        database_port: 1, # required
        database_name: "DatabaseName", # required
        table_name: "TableName", # required
        secret_arn: "SecretArn", # required
      },
      vpc_configuration: {
        subnet_ids: ["SubnetId"], # required
        security_group_ids: ["VpcSecurityGroupId"], # required
      },
      column_configuration: { # required
        document_id_column_name: "ColumnName", # required
        document_data_column_name: "ColumnName", # required
        document_title_column_name: "ColumnName",
        field_mappings: [
          {
            data_source_field_name: "DataSourceFieldName", # required
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName", # required
          },
        ],
        change_detecting_columns: ["ColumnName"], # required
      },
      acl_configuration: {
        allowed_groups_column_name: "ColumnName", # required
      },
      sql_configuration: {
        query_identifiers_enclosing_option: "DOUBLE_QUOTES", # accepts DOUBLE_QUOTES, NONE
      },
    },
    salesforce_configuration: {
      server_url: "Url", # required
      secret_arn: "SecretArn", # required
      standard_object_configurations: [
        {
          name: "ACCOUNT", # required, accepts ACCOUNT, CAMPAIGN, CASE, CONTACT, CONTRACT, DOCUMENT, GROUP, IDEA, LEAD, OPPORTUNITY, PARTNER, PRICEBOOK, PRODUCT, PROFILE, SOLUTION, TASK, USER
          document_data_field_name: "DataSourceFieldName", # required
          document_title_field_name: "DataSourceFieldName",
          field_mappings: [
            {
              data_source_field_name: "DataSourceFieldName", # required
              date_field_format: "DataSourceDateFieldFormat",
              index_field_name: "IndexFieldName", # required
            },
          ],
        },
      ],
      knowledge_article_configuration: {
        included_states: ["DRAFT"], # required, accepts DRAFT, PUBLISHED, ARCHIVED
        standard_knowledge_article_type_configuration: {
          document_data_field_name: "DataSourceFieldName", # required
          document_title_field_name: "DataSourceFieldName",
          field_mappings: [
            {
              data_source_field_name: "DataSourceFieldName", # required
              date_field_format: "DataSourceDateFieldFormat",
              index_field_name: "IndexFieldName", # required
            },
          ],
        },
        custom_knowledge_article_type_configurations: [
          {
            name: "SalesforceCustomKnowledgeArticleTypeName", # required
            document_data_field_name: "DataSourceFieldName", # required
            document_title_field_name: "DataSourceFieldName",
            field_mappings: [
              {
                data_source_field_name: "DataSourceFieldName", # required
                date_field_format: "DataSourceDateFieldFormat",
                index_field_name: "IndexFieldName", # required
              },
            ],
          },
        ],
      },
      chatter_feed_configuration: {
        document_data_field_name: "DataSourceFieldName", # required
        document_title_field_name: "DataSourceFieldName",
        field_mappings: [
          {
            data_source_field_name: "DataSourceFieldName", # required
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName", # required
          },
        ],
        include_filter_types: ["ACTIVE_USER"], # accepts ACTIVE_USER, STANDARD_USER
      },
      crawl_attachments: false,
      standard_object_attachment_configuration: {
        document_title_field_name: "DataSourceFieldName",
        field_mappings: [
          {
            data_source_field_name: "DataSourceFieldName", # required
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName", # required
          },
        ],
      },
      include_attachment_file_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      exclude_attachment_file_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
    },
    one_drive_configuration: {
      tenant_domain: "TenantDomain", # required
      secret_arn: "SecretArn", # required
      one_drive_users: { # required
        one_drive_user_list: ["OneDriveUser"],
        one_drive_user_s3_path: {
          bucket: "S3BucketName", # required
          key: "S3ObjectKey", # required
        },
      },
      inclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      exclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      field_mappings: [
        {
          data_source_field_name: "DataSourceFieldName", # required
          date_field_format: "DataSourceDateFieldFormat",
          index_field_name: "IndexFieldName", # required
        },
      ],
      disable_local_groups: false,
    },
    service_now_configuration: {
      host_url: "ServiceNowHostUrl", # required
      secret_arn: "SecretArn", # required
      service_now_build_version: "LONDON", # required, accepts LONDON, OTHERS
      knowledge_article_configuration: {
        crawl_attachments: false,
        include_attachment_file_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
        exclude_attachment_file_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
        document_data_field_name: "DataSourceFieldName", # required
        document_title_field_name: "DataSourceFieldName",
        field_mappings: [
          {
            data_source_field_name: "DataSourceFieldName", # required
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName", # required
          },
        ],
      },
      service_catalog_configuration: {
        crawl_attachments: false,
        include_attachment_file_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
        exclude_attachment_file_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
        document_data_field_name: "DataSourceFieldName", # required
        document_title_field_name: "DataSourceFieldName",
        field_mappings: [
          {
            data_source_field_name: "DataSourceFieldName", # required
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName", # required
          },
        ],
      },
    },
    confluence_configuration: {
      server_url: "Url", # required
      secret_arn: "SecretArn", # required
      version: "CLOUD", # required, accepts CLOUD, SERVER
      space_configuration: {
        crawl_personal_spaces: false,
        crawl_archived_spaces: false,
        include_spaces: ["ConfluenceSpaceIdentifier"],
        exclude_spaces: ["ConfluenceSpaceIdentifier"],
        space_field_mappings: [
          {
            data_source_field_name: "DISPLAY_URL", # accepts DISPLAY_URL, ITEM_TYPE, SPACE_KEY, URL
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName",
          },
        ],
      },
      page_configuration: {
        page_field_mappings: [
          {
            data_source_field_name: "AUTHOR", # accepts AUTHOR, CONTENT_STATUS, CREATED_DATE, DISPLAY_URL, ITEM_TYPE, LABELS, MODIFIED_DATE, PARENT_ID, SPACE_KEY, SPACE_NAME, URL, VERSION
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName",
          },
        ],
      },
      blog_configuration: {
        blog_field_mappings: [
          {
            data_source_field_name: "AUTHOR", # accepts AUTHOR, DISPLAY_URL, ITEM_TYPE, LABELS, PUBLISH_DATE, SPACE_KEY, SPACE_NAME, URL, VERSION
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName",
          },
        ],
      },
      attachment_configuration: {
        crawl_attachments: false,
        attachment_field_mappings: [
          {
            data_source_field_name: "AUTHOR", # accepts AUTHOR, CONTENT_TYPE, CREATED_DATE, DISPLAY_URL, FILE_SIZE, ITEM_TYPE, PARENT_ID, SPACE_KEY, SPACE_NAME, URL, VERSION
            date_field_format: "DataSourceDateFieldFormat",
            index_field_name: "IndexFieldName",
          },
        ],
      },
      vpc_configuration: {
        subnet_ids: ["SubnetId"], # required
        security_group_ids: ["VpcSecurityGroupId"], # required
      },
      inclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
      exclusion_patterns: ["DataSourceInclusionsExclusionsStringsMember"],
    },
  },
  description: "Description",
  schedule: "ScanSchedule",
  role_arn: "RoleArn",
  tags: [
    {
      key: "TagKey", # required
      value: "TagValue", # required
    },
  ],
  client_token: "ClientTokenName",
}

Instance Attribute Summary collapse

Instance Attribute Details

#client_tokenString

A token that you provide to identify the request to create a data source. Multiple calls to the CreateDataSource operation with the same client token will create only one data source.

Returns:

  • (String)

    A token that you provide to identify the request to create a data source.

#configurationTypes::DataSourceConfiguration

The connector configuration information that is required to access the repository.

You can\'t specify the Configuration parameter when the Type parameter is set to CUSTOM. If you do, you receive a ValidationException exception.

The Configuration parameter is required for all other data sources.

Returns:

#descriptionString

A description for the data source.

Returns:

  • (String)

    A description for the data source.

#index_idString

The identifier of the index that should be associated with this data source.

Returns:

  • (String)

    The identifier of the index that should be associated with this data source.

#nameString

A unique name for the data source. A data source name can\'t be changed without deleting and recreating the data source.

Returns:

  • (String)

    A unique name for the data source.

#role_arnString

The Amazon Resource Name (ARN) of a role with permission to access the data source. For more information, see IAM Roles for Amazon Kendra.

You can\'t specify the RoleArn parameter when the Type parameter is set to CUSTOM. If you do, you receive a ValidationException exception.

The RoleArn parameter is required for all other data sources.

Returns:

  • (String)

    The Amazon Resource Name (ARN) of a role with permission to access the data source.

#scheduleString

Sets the frequency that Amazon Kendra will check the documents in your repository and update the index. If you don\'t set a schedule Amazon Kendra will not periodically update the index. You can call the StartDataSourceSyncJob operation to update the index.

You can\'t specify the Schedule parameter when the Type parameter is set to CUSTOM. If you do, you receive a ValidationException exception.

Returns:

  • (String)

    Sets the frequency that Amazon Kendra will check the documents in your repository and update the index.

#tagsArray<Types::Tag>

A list of key-value pairs that identify the data source. You can use the tags to identify and organize your resources and to control access to resources.

Returns:

  • (Array<Types::Tag>)

    A list of key-value pairs that identify the data source.

#typeString

The type of repository that contains the data source.

Possible values:

  • S3
  • SHAREPOINT
  • DATABASE
  • SALESFORCE
  • ONEDRIVE
  • SERVICENOW
  • CUSTOM
  • CONFLUENCE

Returns:

  • (String)

    The type of repository that contains the data source.