Skip to main content

user_profiles

Creates, updates, deletes, gets or lists a user_profiles resource.

Overview

Nameuser_profiles
TypeResource
Idaws.sagemaker.user_profiles

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
creation_timestring (date-time)The creation time.
domain_idstringThe ID of the domain that contains the profile. (pattern: <code>d-(-*[a-z0-9]){1,61}</code>)
failure_reasonstringThe failure reason.
home_efs_file_system_uidstringThe ID of the user's profile in the Amazon Elastic File System volume. (pattern: <code>\d+</code>)
last_modified_timestring (date-time)The last modified time.
single_sign_on_user_identifierstringThe IAM Identity Center user identifier. (pattern: <code>UserName</code>)
single_sign_on_user_valuestringThe IAM Identity Center user value.
statusstringThe status. (Deleting, Failed, InService, Pending, Updating, Update_Failed, Delete_Failed)
user_profile_arnstringThe user profile Amazon Resource Name (ARN). (pattern: <code>arn:aws[a-z-]:sagemaker:[a-z0-9-]:[0-9]{12}:user-profile/.*</code>)
user_profile_namestringThe user profile name. (pattern: <code>[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}</code>)
user_settingsobjectA collection of settings.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_user_profileselectregionDescribes a user profile. For more information, see CreateUserProfile.
list_user_profilesselectregionLists user profiles.
create_user_profileinsertregion, DomainId, UserProfileNameCreates a user profile. A user profile represents a single user within a domain, and is the main way to reference a "person" for the purposes of sharing, reporting, and other user-oriented features. This entity is created when a user onboards to a domain. If an administrator invites a person by email or imports them from IAM Identity Center, a user profile is automatically created. A user profile is the primary holder of settings for an individual user and has a reference to the user's private Amazon Elastic File System home directory.
update_user_profileupdateregion, DomainId, UserProfileNameUpdates a user profile.
delete_user_profiledeleteregionDeletes a user profile. When a user profile is deleted, the user loses access to their EFS volume, including data, notebooks, and other artifacts.
create_presigned_domain_urlexecregion, DomainId, UserProfileNameCreates a URL for a specified UserProfile in a Domain. When accessed in a web browser, the user will be automatically signed in to the domain, and granted access to all of the Apps and files associated with the Domain's Amazon Elastic File System volume. This operation can only be called when the authentication mode equals IAM. The IAM role or user passed to this API defines the permissions to access the app. Once the presigned URL is created, no additional permission is required to access this URL. IAM authorization policies for this API are also enforced for every HTTP request and WebSocket frame that attempts to connect to the app. You can restrict access to this API and to the URL that it returns to a list of IP addresses, Amazon VPCs or Amazon VPC Endpoints that you specify. For more information, see Connect to Amazon SageMaker AI Studio Through an Interface VPC Endpoint . The URL that you get from a call to CreatePresignedDomainUrl has a default timeout of 5 minutes. You can configure this value using ExpiresInSeconds. If you try to use the URL after the timeout limit expires, you are directed to the Amazon Web Services console sign-in page. The JupyterLab session default expiration time is 12 hours. You can configure this value using SessionExpirationDurationInSeconds.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Describes a user profile. For more information, see CreateUserProfile.

SELECT
creation_time,
domain_id,
failure_reason,
home_efs_file_system_uid,
last_modified_time,
single_sign_on_user_identifier,
single_sign_on_user_value,
status,
user_profile_arn,
user_profile_name,
user_settings
FROM aws.sagemaker.user_profiles
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a user profile. A user profile represents a single user within a domain, and is the main way to reference a "person" for the purposes of sharing, reporting, and other user-oriented features. This entity is created when a user onboards to a domain. If an administrator invites a person by email or imports them from IAM Identity Center, a user profile is automatically created. A user profile is the primary holder of settings for an individual user and has a reference to the user's private Amazon Elastic File System home directory.

INSERT INTO aws.sagemaker.user_profiles (
DomainId,
UserProfileName,
SingleSignOnUserIdentifier,
SingleSignOnUserValue,
Tags,
UserSettings,
region
)
SELECT
'{{ DomainId }}' /* required */,
'{{ UserProfileName }}' /* required */,
'{{ SingleSignOnUserIdentifier }}',
'{{ SingleSignOnUserValue }}',
'{{ Tags }}',
'{{ UserSettings }}',
'{{ region }}'
RETURNING
user_profile_arn
;

UPDATE examples

Updates a user profile.

UPDATE aws.sagemaker.user_profiles
SET
DomainId = '{{ DomainId }}',
UserProfileName = '{{ UserProfileName }}',
UserSettings = '{{ UserSettings }}'
WHERE
region = '{{ region }}' --required
AND DomainId = '{{ DomainId }}' --required
AND UserProfileName = '{{ UserProfileName }}' --required
RETURNING
user_profile_arn;

DELETE examples

Deletes a user profile. When a user profile is deleted, the user loses access to their EFS volume, including data, notebooks, and other artifacts.

DELETE FROM aws.sagemaker.user_profiles
WHERE region = '{{ region }}' --required
;

Lifecycle Methods

Creates a URL for a specified UserProfile in a Domain. When accessed in a web browser, the user will be automatically signed in to the domain, and granted access to all of the Apps and files associated with the Domain's Amazon Elastic File System volume. This operation can only be called when the authentication mode equals IAM. The IAM role or user passed to this API defines the permissions to access the app. Once the presigned URL is created, no additional permission is required to access this URL. IAM authorization policies for this API are also enforced for every HTTP request and WebSocket frame that attempts to connect to the app. You can restrict access to this API and to the URL that it returns to a list of IP addresses, Amazon VPCs or Amazon VPC Endpoints that you specify. For more information, see Connect to Amazon SageMaker AI Studio Through an Interface VPC Endpoint . The URL that you get from a call to CreatePresignedDomainUrl has a default timeout of 5 minutes. You can configure this value using ExpiresInSeconds. If you try to use the URL after the timeout limit expires, you are directed to the Amazon Web Services console sign-in page. The JupyterLab session default expiration time is 12 hours. You can configure this value using SessionExpirationDurationInSeconds.

EXEC aws.sagemaker.user_profiles.create_presigned_domain_url
@region='{{ region }}' --required
@@json=
'{
"DomainId": "{{ DomainId }}",
"UserProfileName": "{{ UserProfileName }}",
"SessionExpirationDurationInSeconds": {{ SessionExpirationDurationInSeconds }},
"ExpiresInSeconds": {{ ExpiresInSeconds }},
"SpaceName": "{{ SpaceName }}",
"LandingUri": "{{ LandingUri }}"
}'
;