update_agent_context
¶
update_agent_context(
agent_context_id: AgentContextIdentifier,
*,
config_overrides: Optional[ContextClientConfig] = None,
name: Optional[ResourceName] = None,
description: Optional[UserDefinedString] = None,
connection_mappings: Optional[ConnectionMappingList] = None,
trace_analysis_config: Optional[TraceAnalysisConfig] = None,
workforce_sign_in_config: Optional[WorkforceSignInConfig] = None,
entity_resolution_config: Optional[EntityResolutionConfig] = None,
trusted_identity_sources: Optional[TrustedIdentitySourceList] = None,
) -> UpdateAgentContextResponse
Updates an agent context's configuration.
Parameters:
-
agent_context_id(AgentContextIdentifier) –The agent context to update, by its ID or ARN.
-
name(Optional[ResourceName], default:None) –The new name. If you omit it, the name is unchanged.
-
description(Optional[UserDefinedString], default:None) –The new description. Absent leaves the description unchanged. An empty string removes it.
-
connection_mappings(Optional[ConnectionMappingList], default:None) –The connection mappings for this agent context, 0–20 entries. If you provide a list, it replaces the stored set: AWS Context removes entries that are not in the list, adds new entries, and overwrites retained entries with exactly the values that you provide, without merging fields. An empty list removes all connection links. If you omit this member, the existing links are unchanged.
Each newly referenced connection must exist, be owned by your account, and be
ACTIVE. 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. -
trace_analysis_config(Optional[TraceAnalysisConfig], default:None) –Merged into the agent context's trace analysis settings: an absent member leaves its stored value unchanged.
statusENABLED requires a role, supplied here or already on the agent context. A role supplied withoutstatusrequires the agent context'sstatusto read ENABLED. -
workforce_sign_in_config(Optional[WorkforceSignInConfig], default:None) –Merged into the agent context's workforce sign-in settings: an absent member leaves its stored value unchanged.
signInUrlreplaces the stored URL and reads ENABLED.statusDISABLED removes the stored URL.statusENABLED requires a URL, supplied here or already on the agent context. -
entity_resolution_config(Optional[EntityResolutionConfig], default:None) –Merged into the agent context's entity resolution settings: an absent member leaves its stored value unchanged.
-
trusted_identity_sources(Optional[TrustedIdentitySourceList], default:None) –Identity sources to trust in addition to your account. A present list replaces the stored list,
[]clears it so only your account is trusted, and an absent field leaves it unchanged. Order is not significant: a list with the stored entries in another order changes nothing. A change takes effect within about a minute.
Raises:
-
AccessDeniedException–You don't have sufficient access to perform this operation. Verify that you have permission to perform the operation on the resource.
-
InternalServerException–The request failed because of an internal error. Retry the request.
-
ThrottlingException–The request was denied because it exceeded a request rate quota. Wait, then retry the request.
-
ValidationException–The input fails to satisfy the constraints of the operation. Correct the input before you retry the request.
-
ConflictException–The request conflicts with the current state of the resource. Check the resource's current state before you retry the request.
-
ResourceNotFoundException–The specified resource was not found. Check that the ID is correct and that the resource exists in your account and Region.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Turn on trace analysis for an agent context The following example turns on trace analysis for the agent context ac-3f9c2e7a1b8d4c56a0e4f7b29d1c8e53 with an IAM role in the same account, and updates its description.
>>> client.update_agent_context(agent_context_id='ac-3f9c2e7a1b8d4c56a0e4f7b29d1c8e53', description='Sales pipeline, revenue, and forecast tables for the analytics agents.', trace_analysis_config={'status': 'ENABLED', 'traceAnalysisRole': 'arn:aws:iam::111122223333:role/ContextTraceAnalysisRole'})
Source code in docs_src/capo_context/_services/context.py
4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 | |