Class: Aws::Kendra::Types::Document

Inherits:
Struct
  • Object
show all
Defined in:
gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb

Overview

Note:

When making an API call, you may pass Document data as a hash:

{
  id: "DocumentId", # required
  title: "Title",
  blob: "data",
  s3_path: {
    bucket: "S3BucketName", # required
    key: "S3ObjectKey", # required
  },
  attributes: [
    {
      key: "DocumentAttributeKey", # required
      value: { # required
        string_value: "DocumentAttributeStringValue",
        string_list_value: ["String"],
        long_value: 1,
        date_value: Time.now,
      },
    },
  ],
  access_control_list: [
    {
      name: "PrincipalName", # required
      type: "USER", # required, accepts USER, GROUP
      access: "ALLOW", # required, accepts ALLOW, DENY
      data_source_id: "DataSourceId",
    },
  ],
  hierarchical_access_control_list: [
    {
      principal_list: [ # required
        {
          name: "PrincipalName", # required
          type: "USER", # required, accepts USER, GROUP
          access: "ALLOW", # required, accepts ALLOW, DENY
          data_source_id: "DataSourceId",
        },
      ],
    },
  ],
  content_type: "PDF", # accepts PDF, HTML, MS_WORD, PLAIN_TEXT, PPT
}

A document in an index.

Constant Summary collapse

SENSITIVE =
[]

Instance Attribute Summary collapse

Instance Attribute Details

#access_control_listArray<Types::Principal>

Information on user and group access rights, which is used for user context filtering.

Returns:



5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#attributesArray<Types::DocumentAttribute>

Custom attributes to apply to the document. Use the custom attributes to provide additional information for searching, to provide facets for refining searches, and to provide additional information in the query response.

For example, 'DataSourceId' and 'DataSourceSyncJobId' are custom attributes that provide information on the synchronization of documents running on a data source. Note, 'DataSourceSyncJobId' could be an optional custom attribute as Amazon Kendra will use the ID of a running sync job.

Returns:



5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#blobString

The contents of the document.

Documents passed to the Blob parameter must be base64 encoded. Your code might not need to encode the document file bytes if you're using an Amazon Web Services SDK to call Amazon Kendra APIs. If you are calling the Amazon Kendra endpoint directly using REST, you must base64 encode the contents before sending.

Returns:

  • (String)


5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#content_typeString

The file type of the document in the Blob field.

Returns:

  • (String)


5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#hierarchical_access_control_listArray<Types::HierarchicalPrincipal>

The list of principal lists that define the hierarchy for which documents users should have access to.

Returns:



5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#idString

A unique identifier of the document in the index.

Returns:

  • (String)


5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#s3_pathTypes::S3Path

Information required to find a specific file in an Amazon S3 bucket.

Returns:



5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end

#titleString

The title of the document.

Returns:

  • (String)


5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
# File 'gems/aws-sdk-kendra/lib/aws-sdk-kendra/types.rb', line 5679

class Document < Struct.new(
  :id,
  :title,
  :blob,
  :s3_path,
  :attributes,
  :access_control_list,
  :hierarchical_access_control_list,
  :content_type)
  SENSITIVE = []
  include Aws::Structure
end