aws_sdk_context/client/create_agent_context.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3 /// Constructs a fluent builder for the [`CreateAgentContext`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder) operation.
4 ///
5 /// - The fluent builder is configurable:
6 /// - [`client_token(impl Into<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::client_token) / [`set_client_token(Option<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_client_token):<br>required: **false**<br><p>Client idempotency token. The AWS SDKs generate one when it is absent. An identical request with the same token returns the existing agent context. The same token with a different request returns ValidationException. <code>trustedIdentitySources</code> with the same entries in another order is the same request.</p><br>
7 /// - [`name(impl Into<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::name) / [`set_name(Option<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_name):<br>required: **false**<br><p>Optional. The name of the agent context. If you omit it, the name is <code>default</code>. You can change it later with UpdateAgentContext.</p><br>
8 /// - [`description(impl Into<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::description) / [`set_description(Option<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_description):<br>required: **false**<br><p>Optional human-readable description of the agent context. An empty string is the same as none.</p><br>
9 /// - [`connection_mappings(ConnectionMapping)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::connection_mappings) / [`set_connection_mappings(Option<Vec::<ConnectionMapping>>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_connection_mappings):<br>required: **true**<br><p>The connection mappings for this agent context, up to 20. CreateAgentContext requires at least one: an empty list returns <code>ValidationException</code>. Each entry binds a connection to one or more ontologies, optionally scoped by a data filter, extraction depth, and path segments. Each referenced connection must exist, be owned by your account, and be <code>ACTIVE</code>. Order is significant. When several connections reach the same AWS Glue Data Catalog table, AWS Context tries the connection mapped first, with its own access, and then the next.</p><br>
10 /// - [`trace_analysis_config(TraceAnalysisConfig)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::trace_analysis_config) / [`set_trace_analysis_config(Option<TraceAnalysisConfig>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_trace_analysis_config):<br>required: **false**<br><p>The agent context's trace analysis settings. Optional. You can change it with UpdateAgentContext.</p><br>
11 /// - [`workforce_sign_in_config(WorkforceSignInConfig)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::workforce_sign_in_config) / [`set_workforce_sign_in_config(Option<WorkforceSignInConfig>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_workforce_sign_in_config):<br>required: **false**<br><p>Optional workforce sign-in settings. A config with <code>signInUrl</code> turns sign-in on (<code>status</code> defaults to ENABLED). <code>status</code> ENABLED without <code>signInUrl</code> is a ValidationException. You can change it with UpdateAgentContext.</p><br>
12 /// - [`entity_resolution_config(EntityResolutionConfig)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::entity_resolution_config) / [`set_entity_resolution_config(Option<EntityResolutionConfig>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_entity_resolution_config):<br>required: **false**<br><p>Optional entity resolution settings. When the config or its <code>status</code> is absent, <code>status</code> reads ENABLED. You can change it with UpdateAgentContext.</p><br>
13 /// - [`trusted_identity_sources(TrustedIdentitySource)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::trusted_identity_sources) / [`set_trusted_identity_sources(Option<Vec::<TrustedIdentitySource>>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_trusted_identity_sources):<br>required: **false**<br><p>Optional identity sources to trust in addition to your account. At most 100 unique entries, each with exactly one member. Order is not significant. An empty list and an absent member are the same value: only your account is trusted. You can change it with UpdateAgentContext.</p><br>
14 /// - [`tags(impl Into<String>, impl Into<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::tags) / [`set_tags(Option<HashMap::<String, String>>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_tags):<br>required: **false**<br><p>Tags to add to the agent context when you create it: up to 200 in the request, of which at most 50 can be user tags. Keys can't start with <code>aws:</code>. To add tags, you also need <code>context:TagResource</code> permission on the new agent context. If you specify more than 50 user tags, the request fails with <code>ServiceQuotaExceededException</code>, as on TagResource. If an AWS Organizations tag policy refuses a tag, the request fails with <code>ValidationException</code>.</p><br>
15 /// - [`curation_policy_ids(impl Into<String>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::curation_policy_ids) / [`set_curation_policy_ids(Option<Vec::<String>>)`](crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::set_curation_policy_ids):<br>required: **false**<br><p>Curation policies to associate with the new agent context, as IDs or ARNs, instead of the default curation policies. If you omit it or the list is empty, AWS Context associates the default curation policies. Each policy must be <code>ACTIVE</code> and owned by your account, and you need <code>context:AssociateCurationPolicy</code> permission on each. AWS Context checks both again on a <code>clientToken</code> retry. If a policy doesn't exist, the request fails with <code>ResourceNotFoundException</code>. If one has been deleted, it fails with <code>ConflictException</code>. Change the policies later with AssociateCurationPolicy and DisassociateCurationPolicy.</p><br>
16 /// - On success, responds with [`CreateAgentContextOutput`](crate::operation::create_agent_context::CreateAgentContextOutput) with field(s):
17 /// - [`id(String)`](crate::operation::create_agent_context::CreateAgentContextOutput::id): <p>The agent context's opaque ID.</p>
18 /// - [`arn(String)`](crate::operation::create_agent_context::CreateAgentContextOutput::arn): <p>The ARN of the agent context, in the form <code>arn:<partition>:context:<region>:<account-id>:agent-context/<id></code>.</p>
19 /// - [`name(String)`](crate::operation::create_agent_context::CreateAgentContextOutput::name): <p>The name of the agent context. If you didn't specify a name when you created it, the name is <code>default</code>.</p>
20 /// - [`description(Option<String>)`](crate::operation::create_agent_context::CreateAgentContextOutput::description): <p>A human-readable description, if one was set.</p>
21 /// - [`status(AgentContextStatus)`](crate::operation::create_agent_context::CreateAgentContextOutput::status): <p>The agent context's lifecycle status.</p> <p>Valid values:</p> <ul> <li> <p><code>CREATING</code> - The agent context is being created.</p></li> <li> <p><code>ACTIVE</code> - The agent context is ready to use.</p></li> <li> <p><code>UPDATING</code> - The agent context is being updated.</p></li> <li> <p><code>DELETING</code> - The agent context is being deleted.</p></li> <li> <p><code>FAILED</code> - The agent context failed.</p></li> </ul>
22 /// - [`created_at(DateTime)`](crate::operation::create_agent_context::CreateAgentContextOutput::created_at): <p>The date and time when the agent context was created.</p>
23 /// - [`updated_at(DateTime)`](crate::operation::create_agent_context::CreateAgentContextOutput::updated_at): <p>When the resource last changed. Equal to <code>createdAt</code> until the first update.</p>
24 /// - [`connection_mappings(Option<Vec::<ConnectionMapping>>)`](crate::operation::create_agent_context::CreateAgentContextOutput::connection_mappings): <p>The agent context's connection mappings.</p>
25 /// - [`encryption_config(Option<EncryptionConfig>)`](crate::operation::create_agent_context::CreateAgentContextOutput::encryption_config): <p>The agent context's encryption settings.</p>
26 /// - [`trace_analysis_config(Option<TraceAnalysisConfig>)`](crate::operation::create_agent_context::CreateAgentContextOutput::trace_analysis_config): <p>The agent context's trace analysis settings.</p>
27 /// - [`workforce_sign_in_config(Option<WorkforceSignInConfig>)`](crate::operation::create_agent_context::CreateAgentContextOutput::workforce_sign_in_config): <p>How your employees sign in to this agent context's MCP server through your identity provider (workforce sign-in). <code>status</code> reads ENABLED while a sign-in URL is stored, DISABLED otherwise.</p>
28 /// - [`entity_resolution_config(Option<EntityResolutionConfig>)`](crate::operation::create_agent_context::CreateAgentContextOutput::entity_resolution_config): <p>The agent context's entity resolution settings. Populated on every response path that returns the resource.</p>
29 /// - [`mcp_server_url(Option<String>)`](crate::operation::create_agent_context::CreateAgentContextOutput::mcp_server_url): <p>The Model Context Protocol (MCP) server URL to give your employees while workforce sign-in is <code>ENABLED</code>. The URL is the agent context's MCP endpoint, with <code>workforceSignInConfig.signInUrl</code> as its <code>login_hint</code> query parameter and the ID that AWS Context assigns to that sign-in URL as its <code>tenantId</code> query parameter. Absent while workforce sign-in is <code>DISABLED</code>.</p>
30 /// - [`trusted_identity_sources(Option<Vec::<TrustedIdentitySource>>)`](crate::operation::create_agent_context::CreateAgentContextOutput::trusted_identity_sources): <p>Identity sources this agent context trusts in addition to its owner's account. Absent or empty: only the owner's account is trusted.</p>
31 /// - On failure, responds with [`SdkError<CreateAgentContextError>`](crate::operation::create_agent_context::CreateAgentContextError)
32 pub fn create_agent_context(&self) -> crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder {
33 crate::operation::create_agent_context::builders::CreateAgentContextFluentBuilder::new(self.handle.clone())
34 }
35}