QBusinessClient.create_data_source
rboto-qbusiness==0.4.0 · Service index · Types
Model summary (excerpt): Creates a data source connector for an Amazon Q Business application. CreateDataSource is a synchronous operation. The operation returns 200 if the data source was successfully created. Otherwise, an exception is raised.
Install and imports
from rboto import QBusinessClient
from collections.abc import Sequence
from rboto_qbusiness.types import (
CreateDataSourceOutput,
DataSourceVpcConfiguration,
DocumentEnrichmentConfiguration,
JSONValue,
MediaExtractionConfiguration,
Tag,
)
Signature
async def create_data_source(
*,
application_id: str,
index_id: str,
display_name: str,
configuration: JSONValue,
vpc_configuration: DataSourceVpcConfiguration | None = None,
description: str | None = None,
tags: Sequence[Tag] | None = None,
sync_schedule: str | None = None,
role_arn: str | None = None,
client_token: str | None = None,
document_enrichment_configuration: DocumentEnrichmentConfiguration | None = None,
media_extraction_configuration: MediaExtractionConfiguration | None = None,
) -> CreateDataSourceOutput: ...
Arguments without defaults are required. None omits an optional request argument. Static types do not validate resource existence, permissions, lengths, ranges, or conditional service requirements.
Arguments
| Argument | Required | Model notes (excerpt) |
|---|---|---|
application_id |
Yes | The identifier of the Amazon Q Business application the data source will be attached to. |
index_id |
Yes | The identifier of the index that you want to use with the data source connector. |
display_name |
Yes | A name for the data source connector. |
configuration |
Yes | Configuration information to connect your data source repository to Amazon Q Business. Use this parameter to provide a JSON schema with configuration information specific to your data source connector. Each data source has a JSON schema provided by Amazon Q Business that you must use. For example, the Amazon S3 and Web Crawler connectors require the following JSON schemas: Amazon S3 JSON... |
vpc_configuration |
No | Configuration information for an Amazon VPC (Virtual Private Cloud) to connect to your data source. For more information, see Using Amazon VPC with Amazon Q Business connectors . |
description |
No | A description for the data source connector. |
tags |
No | A list of key-value pairs that identify or categorize the data source connector. You can also use tags to help control access to the data source connector. Tag keys and values can consist of Unicode letters, digits, white space, and any of the following symbols: _ . : / = + - @. |
sync_schedule |
No | Sets the frequency for Amazon Q Business to check the documents in your data source repository and update your index. If you don't set a schedule, Amazon Q Business won't periodically update the index. Specify a cron- format schedule string or an empty string to indicate that the index is updated on demand. You can't specify the Schedule parameter when the Type parameter is set to CUSTOM . If... |
role_arn |
No | The Amazon Resource Name (ARN) of an IAM role with permission to access the data source and required resources. This field is required for all connector types except custom connectors, where it is optional. |
client_token |
No | A token you provide to identify a request to create a data source connector. Multiple calls to the CreateDataSource API with the same client token will create only one data source connector. |
document_enrichment_configuration |
No | |
media_extraction_configuration |
No | The configuration for extracting information from media in documents during ingestion. |
Output
CreateDataSourceOutput.
Read-only native attributes, accessed as response.field. Collection getters materialize Python values; to_dict() recursively materializes a mapping. Streams are consumed once.
| Field | Type | Presence | References |
|---|---|---|---|
data_source_id |
str | None |
Always present | — |
data_source_arn |
str | None |
Always present | — |
| None means a value can be absent. Output mappings include every declared key; optional input keys may be omitted. Unknown output enum/union variants are not automatically valid inputs.
Related types
CreateDataSourceOutput, DataSourceVpcConfiguration, DocumentEnrichmentConfiguration, JSONValue, MediaExtractionConfiguration, Tag
Follow these links for nested inputs and outputs; recursive types link back to the same type page.
Pagination and streaming
No generated paginator for this operation.
No output stream.
Errors
Import from rboto_qbusiness.exceptions:
AccessDeniedError, ConflictError, InternalServerError, ResourceNotFoundError, ServiceQuotaExceededError, ThrottlingError, ValidationError.
Other service failures use the service base error; credential, transport and timeout failures use shared errors.