documents
Creates, updates, deletes, gets or lists a documents resource.
Overview
| Name | documents |
| Type | Resource |
| Id | aws.qbusiness.documents |
Fields
The following fields are returned by SELECT queries:
- list_documents
| Name | Datatype | Description |
|---|---|---|
created_at | string (date-time) | The timestamp for when the document was created. |
document_id | string | The identifier of the document. (pattern: <code>\P{C}*</code>) |
error | object | Provides information about a Amazon Q Business request error. |
status | string | The current status of the document. (RECEIVED, PROCESSING, INDEXED, UPDATED, FAILED, DELETING, DELETED, DOCUMENT_FAILED_TO_INDEX) |
updated_at | string (date-time) | The timestamp for when the document was last updated. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list_documents | select | application_id, index_id, region | dataSourceIds, nextToken, maxResults | A list of documents attached to an index. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
application_id | string | The identifier of the application id the documents are attached to. |
index_id | string | The identifier of the index the documents are attached to. |
region | string | AWS region (default: us-east-1) |
dataSourceIds | array | The identifier of the data sources the documents are attached to. |
maxResults | integer | The maximum number of documents to return. |
nextToken | string | If the maxResults response was incomplete because there is more data to retrieve, Amazon Q Business returns a pagination token in the response. You can use this pagination token to retrieve the next set of documents. |
SELECT examples
- list_documents
A list of documents attached to an index.
SELECT
created_at,
document_id,
error,
status,
updated_at
FROM aws.qbusiness.documents
WHERE application_id = '{{ application_id }}' -- required
AND index_id = '{{ index_id }}' -- required
AND region = '{{ region }}' -- required
AND dataSourceIds = '{{ dataSourceIds }}'
AND nextToken = '{{ nextToken }}'
AND maxResults = '{{ maxResults }}'
;