Kendra
public struct Kendra
Client object for interacting with AWS Kendra service.
Amazon Kendra is a service for indexing large document sets.
-
Undocumented
Declaration
Swift
public let client: AWSClient
-
Initialize the Kendra client
Declaration
Swift
public init(accessKeyId: String? = nil, secretAccessKey: String? = nil, sessionToken: String? = nil, region: AWSSDKSwiftCore.Region? = nil, endpoint: String? = nil, middlewares: [AWSServiceMiddleware] = [], eventLoopGroupProvider: AWSClient.EventLoopGroupProvider = .useAWSClientShared)
Parameters
accessKeyId
Public access key provided by AWS
secretAccessKey
Private access key provided by AWS
sessionToken
Token provided by STS.AssumeRole() which allows access to another AWS account
region
Region of server you want to communicate with
endpoint
Custom endpoint URL to use instead of standard AWS servers
middlewares
Array of middlewares to apply to requests and responses
eventLoopGroupProvider
EventLoopGroup to use. Use
useAWSClientShared
if the client shall manage its own EventLoopGroup.
-
Removes one or more documents from an index. The documents must have been added with the BatchPutDocument operation. The documents are deleted asynchronously. You can see the progress of the deletion by using AWS CloudWatch. Any error messages releated to the processing of the batch are sent to you CloudWatch log.
Declaration
Swift
public func batchDeleteDocument(_ input: BatchDeleteDocumentRequest) -> EventLoopFuture<BatchDeleteDocumentResponse>
-
Adds one or more documents to an index. The BatchPutDocument operation enables you to ingest inline documents or a set of documents stored in an Amazon S3 bucket. Use this operation to ingest your text and unstructured text into an index, add custom attributes to the documents, and to attach an access control list to the documents added to the index. The documents are indexed asynchronously. You can see the progress of the batch using AWS CloudWatch. Any error messages related to processing the batch are sent to your AWS CloudWatch log.
Declaration
Swift
public func batchPutDocument(_ input: BatchPutDocumentRequest) -> EventLoopFuture<BatchPutDocumentResponse>
-
Creates a data source that you use to with an Amazon Kendra index. You specify a name, connector type and description for your data source. You can choose between an S3 connector, a SharePoint Online connector, and a database connector. You also specify configuration information such as document metadata (author, source URI, and so on) and user context information. CreateDataSource is a synchronous operation. The operation returns 200 if the data source was successfully created. Otherwise, an exception is raised.
Declaration
Swift
public func createDataSource(_ input: CreateDataSourceRequest) -> EventLoopFuture<CreateDataSourceResponse>
-
Creates an new set of frequently asked question (FAQ) questions and answers.
Declaration
Swift
public func createFaq(_ input: CreateFaqRequest) -> EventLoopFuture<CreateFaqResponse>
-
Creates a new Amazon Kendra index. Index creation is an asynchronous operation. To determine if index creation has completed, check the Status field returned from a call to . The Status field is set to ACTIVE when the index is ready to use. Once the index is active you can index your documents using the operation or using one of the supported data sources.
Declaration
Swift
public func createIndex(_ input: CreateIndexRequest) -> EventLoopFuture<CreateIndexResponse>
-
Deletes an Amazon Kendra data source. An exception is not thrown if the data source is already being deleted. While the data source is being deleted, the Status field returned by a call to the operation is set to DELETING. For more information, see Deleting Data Sources.
Declaration
Swift
@discardableResult public func deleteDataSource(_ input: DeleteDataSourceRequest) -> EventLoopFuture<Void>
-
Removes an FAQ from an index.
Declaration
Swift
@discardableResult public func deleteFaq(_ input: DeleteFaqRequest) -> EventLoopFuture<Void>
-
Deletes an existing Amazon Kendra index. An exception is not thrown if the index is already being deleted. While the index is being deleted, the Status field returned by a call to the DescribeIndex operation is set to DELETING.
Declaration
Swift
@discardableResult public func deleteIndex(_ input: DeleteIndexRequest) -> EventLoopFuture<Void>
-
Gets information about a Amazon Kendra data source.
Declaration
Swift
public func describeDataSource(_ input: DescribeDataSourceRequest) -> EventLoopFuture<DescribeDataSourceResponse>
-
Gets information about an FAQ list.
Declaration
Swift
public func describeFaq(_ input: DescribeFaqRequest) -> EventLoopFuture<DescribeFaqResponse>
-
Describes an existing Amazon Kendra index
Declaration
Swift
public func describeIndex(_ input: DescribeIndexRequest) -> EventLoopFuture<DescribeIndexResponse>
-
Gets statistics about synchronizing Amazon Kendra with a data source.
Declaration
Swift
public func listDataSourceSyncJobs(_ input: ListDataSourceSyncJobsRequest) -> EventLoopFuture<ListDataSourceSyncJobsResponse>
-
Lists the data sources that you have created.
Declaration
Swift
public func listDataSources(_ input: ListDataSourcesRequest) -> EventLoopFuture<ListDataSourcesResponse>
-
Gets a list of FAQ lists associated with an index.
Declaration
Swift
public func listFaqs(_ input: ListFaqsRequest) -> EventLoopFuture<ListFaqsResponse>
-
Lists the Amazon Kendra indexes that you have created.
Declaration
Swift
public func listIndices(_ input: ListIndicesRequest) -> EventLoopFuture<ListIndicesResponse>
-
Gets a list of tags associated with a specified resource. Indexes, FAQs, and data sources can have tags associated with them.
Declaration
Swift
public func listTagsForResource(_ input: ListTagsForResourceRequest) -> EventLoopFuture<ListTagsForResourceResponse>
-
Searches an active index. Use this API to search your documents using query. The Query operation enables to do faceted search and to filter results based on document attributes. It also enables you to provide user context that Amazon Kendra uses to enforce document access control in the search results. Amazon Kendra searches your index for text content and question and answer (FAQ) content. By default the response contains three types of results. Relevant passages Matching FAQs Relevant documents You can specify that the query return only one type of result using the QueryResultTypeConfig parameter.
Declaration
Swift
public func query(_ input: QueryRequest) -> EventLoopFuture<QueryResult>
-
Starts a synchronization job for a data source. If a synchronization job is already in progress, Amazon Kendra returns a ResourceInUseException exception.
Declaration
Swift
public func startDataSourceSyncJob(_ input: StartDataSourceSyncJobRequest) -> EventLoopFuture<StartDataSourceSyncJobResponse>
-
Stops a running synchronization job. You can’t stop a scheduled synchronization job.
Declaration
Swift
@discardableResult public func stopDataSourceSyncJob(_ input: StopDataSourceSyncJobRequest) -> EventLoopFuture<Void>
-
Enables you to provide feedback to Amazon Kendra to improve the performance of the service.
Declaration
Swift
@discardableResult public func submitFeedback(_ input: SubmitFeedbackRequest) -> EventLoopFuture<Void>
-
Adds the specified tag to the specified index, FAQ, or data source resource. If the tag already exists, the existing value is replaced with the new value.
Declaration
Swift
public func tagResource(_ input: TagResourceRequest) -> EventLoopFuture<TagResourceResponse>
-
Removes a tag from an index, FAQ, or a data source.
Declaration
Swift
public func untagResource(_ input: UntagResourceRequest) -> EventLoopFuture<UntagResourceResponse>
-
Updates an existing Amazon Kendra data source.
Declaration
Swift
@discardableResult public func updateDataSource(_ input: UpdateDataSourceRequest) -> EventLoopFuture<Void>
-
Updates an existing Amazon Kendra index.
Declaration
Swift
@discardableResult public func updateIndex(_ input: UpdateIndexRequest) -> EventLoopFuture<Void>
-
Gets statistics about synchronizing Amazon Kendra with a data source.
Declaration
Swift
public func listDataSourceSyncJobsPaginator(_ input: ListDataSourceSyncJobsRequest, onPage: @escaping (ListDataSourceSyncJobsResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>
-
Lists the data sources that you have created.
Declaration
Swift
public func listDataSourcesPaginator(_ input: ListDataSourcesRequest, onPage: @escaping (ListDataSourcesResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>
-
Lists the Amazon Kendra indexes that you have created.
Declaration
Swift
public func listIndicesPaginator(_ input: ListIndicesRequest, onPage: @escaping (ListIndicesResponse, EventLoop) -> EventLoopFuture<Bool>) -> EventLoopFuture<Void>
-
Undocumented
See moreDeclaration
Swift
public struct ListDataSourceSyncJobsRequest : AWSShape
extension Kendra.ListDataSourceSyncJobsRequest: AWSPaginateStringToken
-
Undocumented
See moreDeclaration
Swift
public struct ListDataSourcesRequest : AWSShape
extension Kendra.ListDataSourcesRequest: AWSPaginateStringToken
-
Undocumented
See moreDeclaration
Swift
public struct ListIndicesRequest : AWSShape
extension Kendra.ListIndicesRequest: AWSPaginateStringToken
-
Undocumented
See moreDeclaration
Swift
public enum AdditionalResultAttributeValueType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum ContentType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum DataSourceStatus : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum DataSourceSyncJobStatus : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum DataSourceType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum DatabaseEngineType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum DocumentAttributeValueType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum ErrorCode : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum FaqStatus : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum IndexEdition : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum IndexStatus : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum Order : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum PrincipalType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum QueryIdentifiersEnclosingOption : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum QueryResultType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum ReadAccessType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum RelevanceType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum SalesforceChatterFeedIncludeFilterType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum SalesforceKnowledgeArticleState : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum SalesforceStandardObjectName : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum ScoreConfidence : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum ServiceNowBuildVersionType : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum SharePointVersion : String, CustomStringConvertible, Codable
-
Undocumented
See moreDeclaration
Swift
public enum SortOrder : String, CustomStringConvertible, Codable