aws-sdk-context 1.0.0

AWS SDK for AWS Context
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl super::Client {
    /// Constructs a fluent builder for the [`StartTask`](crate::operation::start_task::builders::StartTaskFluentBuilder) operation.
    ///
    /// - The fluent builder is configurable:
    ///   - [`agent_context_id(impl Into<String>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::agent_context_id) / [`set_agent_context_id(Option<String>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::set_agent_context_id):<br>required: **true**<br><p>The agent context, as an ID or ARN.</p><br>
    ///   - [`client_token(impl Into<String>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::client_token) / [`set_client_token(Option<String>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::set_client_token):<br>required: **false**<br><p>A unique, case-sensitive identifier that you provide to ensure that the request completes no more than one time. The token is scoped to your account and the agent context. If you reuse a token on the same agent context with different parameters, the request fails with <code>ValidationException</code>.</p><br>
    ///   - [`description(impl Into<String>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::description) / [`set_description(Option<String>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::set_description):<br>required: **false**<br><p>A description of the task. Up to 1,024 characters, with no control characters.</p><br>
    ///   - [`input_configuration(TaskInputConfiguration)`](crate::operation::start_task::builders::StartTaskFluentBuilder::input_configuration) / [`set_input_configuration(Option<TaskInputConfiguration>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::set_input_configuration):<br>required: **true**<br><p>What the task imports. Set exactly one member. The member that you set determines the task's <code>type</code>.</p><br>
    ///   - [`access_control_config(AccessControlConfig)`](crate::operation::start_task::builders::StartTaskFluentBuilder::access_control_config) / [`set_access_control_config(Option<AccessControlConfig>)`](crate::operation::start_task::builders::StartTaskFluentBuilder::set_access_control_config):<br>required: **false**<br><p>Who can see the content that the task adds to the agent context. AWS Context supports only one entry: <code>ALLOW</code> with <code>principalId</code> <code>*</code>, so that every reader of the agent context can see it. If you omit it or send no entries, AWS Context uses that entry. If you name any other principal, include a <code>DENY</code> entry, or send more than one entry, the request fails with <code>ValidationException</code>, and no task is started.</p><br>
    /// - On success, responds with [`StartTaskOutput`](crate::operation::start_task::StartTaskOutput) with field(s):
    ///   - [`id(String)`](crate::operation::start_task::StartTaskOutput::id): <p>The ID of the task. Pass it as <code>taskId</code> to GetTask or CancelTask.</p>
    ///   - [`arn(String)`](crate::operation::start_task::StartTaskOutput::arn): <p>The Amazon Resource Name (ARN) of the task.</p>
    ///   - [`agent_context_id(String)`](crate::operation::start_task::StartTaskOutput::agent_context_id): <p>The agent context's ID.</p>
    ///   - [`r#type(TaskType)`](crate::operation::start_task::StartTaskOutput::type): <p>The type of the task. It is set by the <code>inputConfiguration</code> member that the task was started with: <code>IMPORT_DATA_DICTIONARY</code>, <code>IMPORT_VERIFIED_QUERIES</code>, or <code>IMPORT_ONTOLOGY</code>.</p>
    ///   - [`status(TaskStatus)`](crate::operation::start_task::StartTaskOutput::status): <p>The status of the task. A task moves from <code>PENDING</code> to <code>IN_PROGRESS</code> and ends <code>COMPLETED</code>, <code>FAILED</code>, or <code>CANCELLED</code>. After CancelTask, it is <code>CANCELLING</code> until it stops.</p>
    ///   - [`description(Option<String>)`](crate::operation::start_task::StartTaskOutput::description): <p>The description of the task, as given to StartTask.</p>
    ///   - [`created_at(DateTime)`](crate::operation::start_task::StartTaskOutput::created_at): <p>The date and time when the task was created.</p>
    ///   - [`updated_at(DateTime)`](crate::operation::start_task::StartTaskOutput::updated_at): <p>The date and time when the task was last updated, such as when its status changed. Equal to <code>createdAt</code> until the task first changes.</p>
    ///   - [`status_reason_code(Option<TaskStatusReasonCode>)`](crate::operation::start_task::StartTaskOutput::status_reason_code): <p>The code for why the task failed. Present only when <code>status</code> is <code>FAILED</code>.</p> <p>Valid values:</p> <ul>  <li>   <p><code>GRAPH_NOT_ACTIVE</code> - The agent context was deleted, or was not yet available, while the task ran.</p></li>  <li>   <p><code>ONTOLOGY_INVALID</code> - An ontology is missing, has no loadable source, or its source is unsafe or too large.</p></li>  <li>   <p><code>ONTOLOGY_IMPORT_UNAVAILABLE</code> - An ontology couldn't be imported because of a temporary problem. Start a new task.</p></li>  <li>   <p><code>ONTOLOGY_ALREADY_IMPORTED</code> - This ontology version is already imported into the agent context.</p></li> </ul>
    ///   - [`status_message(Option<String>)`](crate::operation::start_task::StartTaskOutput::status_message): <p>The reason the task failed. Present only when status is FAILED.</p>
    ///   - [`statistics(Option<TaskStatistics>)`](crate::operation::start_task::StartTaskOutput::statistics): <p>Counts of the documents that the task analyzed and the change sets that it created. The counts are final once the task is <code>COMPLETED</code>, <code>FAILED</code>, or <code>CANCELLED</code>.</p>
    ///   - [`input_configuration(Option<TaskInputConfigurationSummary>)`](crate::operation::start_task::StartTaskOutput::input_configuration): <p>A summary of the input that the task was started with. Each document is returned as its name, size, and content type, not its content, and each ontology is returned as its ARN and, if set, its version.</p>
    ///   - [`outputs(Option<Vec::<TaskOutput>>)`](crate::operation::start_task::StartTaskOutput::outputs): <p>What the task created, in creation order. Set when it finishes.</p>
    /// - On failure, responds with [`SdkError<StartTaskError>`](crate::operation::start_task::StartTaskError)
    pub fn start_task(&self) -> crate::operation::start_task::builders::StartTaskFluentBuilder {
        crate::operation::start_task::builders::StartTaskFluentBuilder::new(self.handle.clone())
    }
}