create_user
async
¶
create_user(
username: AgentUsername,
security_profile_ids: SecurityProfileIds,
routing_profile_id: RoutingProfileId,
instance_id: InstanceId,
*,
config_overrides: Optional[AsyncConnectClientConfig] = None,
password: Optional[Password] = None,
identity_info: Optional[UserIdentityInfo] = None,
phone_config: Optional[UserPhoneConfig] = None,
directory_user_id: Optional[DirectoryUserId] = None,
hierarchy_group_id: Optional[HierarchyGroupId] = None,
auto_accept_configs: Optional[AutoAcceptConfigs] = None,
after_contact_work_configs: Optional[AfterContactWorkConfigs] = None,
phone_number_configs: Optional[PhoneNumberConfigs] = None,
persistent_connection_configs: Optional[PersistentConnectionConfigs] = None,
voice_enhancement_configs: Optional[VoiceEnhancementConfigs] = None,
tags: Optional[TagMap] = None,
) -> CreateUserResponse
Creates a user account for the specified Connect Customer instance.
Certain UserIdentityInfo parameters are required in some situations. For example, Email, FirstName and LastName are required if you are using Connect Customer or SAML for identity management.
Fields in PhoneConfig cannot be set simultaneously with their corresponding channel-specific configuration parameters. Specifically:
-
PhoneConfig.AutoAcceptconflicts withAutoAcceptConfigs -
PhoneConfig.AfterContactWorkTimeLimitconflicts withAfterContactWorkConfigs -
PhoneConfig.PhoneTypeandPhoneConfig.PhoneNumberconflict withPhoneNumberConfigs -
PhoneConfig.PersistentConnectionconflicts withPersistentConnectionConfigs
We recommend using channel-specific parameters such as AutoAcceptConfigs, AfterContactWorkConfigs, PhoneNumberConfigs, PersistentConnectionConfigs, and VoiceEnhancementConfigs for per-channel configuration.
For information about how to create users using the Connect Customer admin website, see Add Users in the Connect Customer Administrator Guide.
Parameters:
-
username(AgentUsername) –The user name for the account. For instances not using SAML for identity management, the user name can include up to 20 characters. If you are using SAML for identity management, the user name can include up to 64 characters from [a-zA-Z0-9_-.\@]+.
Username can include @ only if used in an email format. For example:
-
Correct: testuser
-
Correct: [email protected]
-
Incorrect: testuser@example
-
-
password(Optional[Password], default:None) –The password for the user account. A password is required if you are using Connect Customer for identity management. Otherwise, it is an error to include a password.
-
identity_info(Optional[UserIdentityInfo], default:None) –The information about the identity of the user.
-
phone_config(Optional[UserPhoneConfig], default:None) –The phone settings for the user. This parameter is optional. If not provided, the user can be configured using channel-specific parameters such as
AutoAcceptConfigs,AfterContactWorkConfigs,PhoneNumberConfigs,PersistentConnectionConfigs, andVoiceEnhancementConfigs. -
directory_user_id(Optional[DirectoryUserId], default:None) –The identifier of the user account in the directory used for identity management. If Connect Customer cannot access the directory, you can specify this identifier to authenticate users. If you include the identifier, we assume that Connect Customer cannot access the directory. Otherwise, the identity information is used to authenticate users from your directory.
This parameter is required if you are using an existing directory for identity management in Connect Customer when Connect Customer cannot access your directory to authenticate users. If you are using SAML for identity management and include this parameter, an error is returned.
-
security_profile_ids(SecurityProfileIds) –The identifier of the security profile for the user.
-
routing_profile_id(RoutingProfileId) –The identifier of the routing profile for the user.
-
hierarchy_group_id(Optional[HierarchyGroupId], default:None) –The identifier of the hierarchy group for the user.
-
instance_id(InstanceId) –The identifier of the Connect Customer instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.
-
auto_accept_configs(Optional[AutoAcceptConfigs], default:None) –The list of auto-accept configuration settings for each channel.
-
after_contact_work_configs(Optional[AfterContactWorkConfigs], default:None) –The list of after contact work (ACW) timeout configuration settings for each channel.
-
phone_number_configs(Optional[PhoneNumberConfigs], default:None) –The list of phone number configuration settings for each channel.
-
persistent_connection_configs(Optional[PersistentConnectionConfigs], default:None) –The list of persistent connection configuration settings for each channel.
-
voice_enhancement_configs(Optional[VoiceEnhancementConfigs], default:None) –The list of voice enhancement configuration settings for each channel.
-
tags(Optional[TagMap], default:None) –The tags used to organize, track, or control access for this resource. For example, { "Tags": {"key1":"value1", "key2":"value2"} }.
Raises:
-
DuplicateResourceException–A resource with the specified name already exists.
-
InternalServiceException–Request processing failed because of an error or failure with the service.
-
InvalidParameterException–One or more of the specified parameters are not valid.
-
InvalidRequestException–The request is not valid.
-
LimitExceededException–The allowed limit for the resource has been exceeded.
-
ResourceNotFoundException–The specified resource was not found.
-
ThrottlingException–The throttling limit has been exceeded.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_connect/_services/async_connect.py
6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 | |