Users
Manage users in the account. Users are human identities (as opposed to programmatic users which are machine identities).
Contents
ListUsers
Lists all users.
Input
| Parameter | Type | Required |
|---|---|---|
nextToken |
string | No |
maxResults |
integer | No |
Sample Request
await client.send(new ListUsersCommand({}));
Output
{ "items": [ { "userId": "user-id-string", "cxnRole": "administrator", "userArn": "arn:aws:connect:us-west-2:123456789:instance/.../user/...", "username": "jane.doe", "firstName": "Jane", "lastName": "Doe", "email": "jane@example.com", "applicationIds": ["05c3fcc2-..."], "roles": [ { "applicationId": "05c3fcc2-...", "role": "administrator" } ], "defaultRole": { "role": "administrator" }, "createdAt": "2026-08-01T12:00:00.000Z", "updatedAt": "2026-08-01T12:00:00.000Z", "updatedBy": "admin-user" } ], "nextToken": null }
Errors
-
ValidationException(400) -
InternalServerException(500)
CreateUser
Creates a new user.
Input
| Parameter | Type | Required |
|---|---|---|
userId |
string | Yes |
cxnRole |
string | Yes |
userArn |
string | Yes |
username |
string | Yes |
firstName |
string | No |
lastName |
string | No |
email |
string | No |
applicationIds |
array | No |
roles |
array | No |
defaultRole |
object | No |
Sample Request
await client.send(new CreateUserCommand({ userId: "00000000-0000-4000-8000-000000000099", cxnRole: "member", userArn: "arn:aws:connect:us-west-2:176202286863:instance/cb0ac315-73ce-4def-a2cc-cf3caf9866cc/agent/00000000-0000-4000-8000-000000000099", username: "sdk.testuser", firstName: "SDK", lastName: "TestUser", email: "sdk-test@example.com", applicationIds: ["a018836f-a909-4be0-a28b-53b413f1429c"], defaultRole: { role: "developer" }, roles: [ { applicationId: "a018836f-a909-4be0-a28b-53b413f1429c", role: "developer" }, ], }));
Output
{ "userId": "00000000-0000-4000-8000-000000000099", "cxnRole": "member", "userArn": "arn:aws:connect:us-west-2:176202286863:instance/cb0ac315-73ce-4def-a2cc-cf3caf9866cc/agent/00000000-0000-4000-8000-000000000099", "username": "sdk.testuser", "firstName": "SDK", "lastName": "TestUser", "email": "sdk-test@example.com", "applicationIds": [ "a018836f-a909-4be0-a28b-53b413f1429c" ], "roles": [ { "applicationId": "a018836f-a909-4be0-a28b-53b413f1429c", "role": "developer" } ], "defaultRole": { "role": "developer" }, "createdAt": "2026-08-10T22:54:16.796Z", "updatedAt": "2026-08-10T22:54:16.796Z", "updatedBy": "deploy-ci-bot" }
Errors
-
ValidationException(400) -
ConflictException(409) -
InternalServerException(500)
GetUser
Gets a single user by ID.
Input
| Parameter | Type | Required |
|---|---|---|
userId |
string | Yes |
Sample Request
await client.send(new GetUserCommand({ userId: "00000000-0000-4000-8000-000000000099", }));
Output
{ "userId": "00000000-0000-4000-8000-000000000099", "cxnRole": "member", "userArn": "arn:aws:connect:us-west-2:<account-id>:instance/cb0ac315-73ce-4def-a2cc-cf3caf9866cc/agent/00000000-0000-4000-8000-000000000099", "username": "sdk.testuser", "firstName": "SDK", "lastName": "TestUser", "email": "sdk-test@example.com", "applicationIds": [ "a018836f-a909-4be0-a28b-53b413f1429c" ], "roles": [ { "applicationId": "a018836f-a909-4be0-a28b-53b413f1429c", "role": "developer" } ], "defaultRole": { "role": "developer" }, "createdAt": "2026-08-10T22:54:16.796Z", "updatedAt": "2026-08-10T22:54:16.796Z", "updatedBy": "deploy-ci-bot" }
Errors
-
ValidationException(400) -
ResourceNotFoundException(404) -
InternalServerException(500)
UpdateUser
Updates a user. Only include fields you want to change.
Input
| Parameter | Type | Required |
|---|---|---|
userId |
string | Yes |
cxnRole |
string | No |
userArn |
string | No |
firstName |
string | No |
lastName |
string | No |
email |
string | No |
applicationIds |
array | No |
roles |
array | No |
defaultRole |
object | No |
Sample Request
await client.send(new UpdateUserCommand({ userId: "00000000-0000-4000-8000-000000000099", cxnRole: "member", userArn: "arn:aws:connect:us-west-2:<account-id>:instance/cb0ac315-73ce-4def-a2cc-cf3caf9866cc/agent/00000000-0000-4000-8000-000000000099", firstName: "SDKUpdated", lastName: "TestUser", email: "sdk-test@example.com", applicationIds: ["a018836f-a909-4be0-a28b-53b413f1429c"], roles: [ { applicationId: "a018836f-a909-4be0-a28b-53b413f1429c", role: "developer" }, ], defaultRole: { role: "contentManager" }, }));
Output
{ "userId": "00000000-0000-4000-8000-000000000099", "cxnRole": "member", "userArn": "arn:aws:connect:us-west-2:<account-id>:instance/cb0ac315-73ce-4def-a2cc-cf3caf9866cc/agent/00000000-0000-4000-8000-000000000099", "username": "sdk.testuser", "firstName": "SDKUpdated", "lastName": "TestUser", "email": "sdk-test@example.com", "applicationIds": [ "a018836f-a909-4be0-a28b-53b413f1429c" ], "roles": [ { "applicationId": "a018836f-a909-4be0-a28b-53b413f1429c", "role": "developer" } ], "defaultRole": { "role": "contentManager" }, "createdAt": "2026-08-10T22:54:16.796Z", "updatedAt": "2026-08-10T22:54:20.530Z", "updatedBy": "deploy-ci-bot" }
Errors
-
ValidationException(400) -
ResourceNotFoundException(404) -
InternalServerException(500)
DeleteUser
Deletes a user.
Input
| Parameter | Type | Required |
|---|---|---|
userId |
string | Yes |
Sample Request
await client.send(new DeleteUserCommand({ userId: created.userId, }));
Output
No response body.
Errors
-
ValidationException(400) -
ResourceNotFoundException(404) -
InternalServerException(500)
Request Parameters
userId-
Type: String
The user identifier.
cxnRole-
Type: String
The user's account-level role. One of:
member,administrator,owner. userArn-
Type: String
The user's Amazon Connect ARN.
username-
Type: String
Username. 1–128 characters.
firstName-
Type: String
First name. 1–36 characters.
lastName-
Type: String
Last name. Max 36 characters.
email-
Type: String
Email address. 3–256 characters.
applicationIds-
Type: Array
Workspace IDs the user can access.
roles-
Type: Array
Per-workspace role assignments. See User Role Assignment.
defaultRole-
Type: Object
Default role when no workspace-specific role applies. See Default Role.
createdAt-
Type: String
When the user was created (ISO 8601).
updatedAt-
Type: String
When the user was last modified (ISO 8601).
updatedBy-
Type: String
The identity of who last modified the user.
nextToken-
Type: String
Pagination token. See Common Types.
maxResults-
Type: Integer
Max items per page (1–100). See Common Types.
User Role Assignment
| Field | Type | Required |
|---|---|---|
applicationId |
string | Yes |
role |
string | Yes |
roleId |
string | No |
applicationId-
Type: String
The workspace this assignment applies to.
role-
Type: String
Pre-defined role name. One of:
administrator,developer,contentManager,readOnly. roleId-
Type: String
Custom role ID (alternative to
role). Created via the Roles API.
Default Role
The fallback role applied when the user accesses a workspace without a specific role assignment.
| Field | Type | Required |
|---|---|---|
role |
string | Yes |
roleId |
string | No |
role-
Type: String
Pre-defined role name. One of:
administrator,developer,contentManager,readOnly. roleId-
Type: String
Custom role ID (alternative to
role).