2026/11/05 - AWS Security Agent - 3 updated api methods
Changes Adds support for IAM Identity Center groups as Agent Space members. CreateMembership, DeleteMembership, and ListMemberships now accept the GROUP member type. ListMemberships can filter by USER, GROUP, or ALL, and returns group display name and description.
{'memberType': {'GROUP'}}
Creates a new membership, granting a user or group access to an agent space within an application.
See also: AWS API Documentation
Request Syntax
client.create_membership(
applicationId='string',
agentSpaceId='string',
membershipId='string',
memberType='USER'|'GROUP',
config={
'user': {
'role': 'MEMBER'
}
}
)
string
[REQUIRED]
The unique identifier of the application that contains the agent space.
string
[REQUIRED]
The unique identifier of the agent space to grant access to.
string
[REQUIRED]
The unique identifier for the membership.
string
[REQUIRED]
The type of member. Use USER for an individual user or GROUP for an IAM Identity Center group. All members of a group have access to the agent space.
dict
The configuration for the membership, such as the user role.
user (dict) --
The user configuration for the membership.
role (string) --
The role assigned to the user. Currently, only MEMBER is supported.
dict
Response Syntax
{}
Response Structure
(dict) --
Response structure for adding a single member to an agent space.
{'memberType': {'GROUP'}}
Deletes a membership, revoking a user's or group's access to an agent space.
See also: AWS API Documentation
Request Syntax
client.delete_membership(
applicationId='string',
agentSpaceId='string',
membershipId='string',
memberType='USER'|'GROUP'
)
string
[REQUIRED]
The unique identifier of the application that contains the agent space.
string
[REQUIRED]
The unique identifier of the agent space to revoke access from.
string
[REQUIRED]
The unique identifier of the membership to delete.
string
The type of member to remove.
dict
Response Syntax
{}
Response Structure
(dict) --
Response structure for removing a single member from an agent space.
{'memberType': {'GROUP'}}
Response {'membershipSummaries': {'memberType': {'GROUP'},
'metadata': {'group': {'description': 'string',
'displayName': 'string'}}}}
Returns a paginated list of membership summaries for the specified agent space within an application.
See also: AWS API Documentation
Request Syntax
client.list_memberships(
applicationId='string',
agentSpaceId='string',
memberType='USER'|'GROUP'|'ALL',
maxResults=123,
nextToken='string'
)
string
[REQUIRED]
The unique identifier of the application that contains the agent space.
string
[REQUIRED]
The unique identifier of the agent space to list memberships for.
string
Filter memberships by member type.
integer
The maximum number of results to return in a single call.
string
A token to use for paginating results that are returned in the response. Set the value of this parameter to null for the first request. For subsequent calls, use the nextToken value returned from the previous request.
dict
Response Syntax
{
'membershipSummaries': [
{
'membershipId': 'string',
'applicationId': 'string',
'agentSpaceId': 'string',
'memberType': 'USER'|'GROUP',
'config': {
'user': {
'role': 'MEMBER'
}
},
'metadata': {
'user': {
'username': 'string',
'email': 'string'
},
'group': {
'displayName': 'string',
'description': 'string'
}
},
'createdAt': datetime(2015, 1, 1),
'updatedAt': datetime(2015, 1, 1),
'createdBy': 'string',
'updatedBy': 'string'
},
],
'nextToken': 'string'
}
Response Structure
(dict) --
Response structure for listing members associated to an agent space.
membershipSummaries (list) --
The list of membership summaries.
(dict) --
Contains summary information about a membership.
membershipId (string) --
The unique identifier of the membership.
applicationId (string) --
The unique identifier of the application.
agentSpaceId (string) --
The unique identifier of the agent space.
memberType (string) --
The type of member.
config (dict) --
The configuration for the membership.
user (dict) --
The user configuration for the membership.
role (string) --
The role assigned to the user. Currently, only MEMBER is supported.
metadata (dict) --
The metadata for the member.
user (dict) --
The user metadata for the member.
username (string) --
The username of the user.
email (string) --
The email address of the user.
group (dict) --
The group metadata for the member.
displayName (string) --
The display name of the group.
description (string) --
The description of the group.
createdAt (datetime) --
The date and time the membership was created, in UTC format.
updatedAt (datetime) --
The date and time the membership was last updated, in UTC format.
createdBy (string) --
The identifier of the entity that created the membership.
updatedBy (string) --
The identifier of the entity that last updated the membership.
nextToken (string) --
A token to use for paginating results that are returned in the response. Set the value of this parameter to null for the first request. For subsequent calls, use the nextToken value returned from the previous request.