create_auth_code
¶
create_auth_code(
instance_id: InstanceId,
scope: AuthScope,
session_inactivity_duration_minutes: SessionInactivityDurationMinutes,
*,
config_overrides: Optional[ConnectClientConfig] = None,
max_session_duration_minutes: Optional[MaxSessionDurationMinutes] = None,
) -> CreateAuthCodeResponse
Creates an authorization code for the specified Connect Customer instance. The authorization code can be used to establish a session with scoped permissions defined by the specified scope parameters.
Parameters:
-
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.
-
scope(AuthScope) –The scope for the authorization code. Defines the permissions and access boundaries for the session.
-
max_session_duration_minutes(Optional[MaxSessionDurationMinutes], default:None) –The maximum duration of the session, in minutes. Minimum value of 1440 (24 hours). Maximum value of 43200 (30 days). If no value is provided, the session will expire after 400 days.
-
session_inactivity_duration_minutes(SessionInactivityDurationMinutes) –The duration of inactivity, in minutes, after which the session expires. Minimum value of 1440 (24 hours). Maximum value of 20160 (14 days).
Raises:
-
AccessDeniedException–You do not have sufficient permissions to perform this action.
-
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.
-
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/connect.py
3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 | |