Struct aws_sdk_cognitoidentityprovider::operation::list_users::builders::ListUsersInputBuilder
source · #[non_exhaustive]pub struct ListUsersInputBuilder { /* private fields */ }
Expand description
A builder for ListUsersInput
.
Implementations§
source§impl ListUsersInputBuilder
impl ListUsersInputBuilder
sourcepub fn user_pool_id(self, input: impl Into<String>) -> Self
pub fn user_pool_id(self, input: impl Into<String>) -> Self
The user pool ID for the user pool on which the search should be performed.
This field is required.sourcepub fn set_user_pool_id(self, input: Option<String>) -> Self
pub fn set_user_pool_id(self, input: Option<String>) -> Self
The user pool ID for the user pool on which the search should be performed.
sourcepub fn get_user_pool_id(&self) -> &Option<String>
pub fn get_user_pool_id(&self) -> &Option<String>
The user pool ID for the user pool on which the search should be performed.
sourcepub fn attributes_to_get(self, input: impl Into<String>) -> Self
pub fn attributes_to_get(self, input: impl Into<String>) -> Self
Appends an item to attributes_to_get
.
To override the contents of this collection use set_attributes_to_get
.
A JSON array of user attribute names, for example given_name
, that you want Amazon Cognito to include in the response for each user. When you don't provide an AttributesToGet
parameter, Amazon Cognito returns all attributes for each user.
Use AttributesToGet
with required attributes in your user pool, or in conjunction with Filter
. Amazon Cognito returns an error if not all users in the results have set a value for the attribute you request. Attributes that you can't filter on, including custom attributes, must have a value set in every user profile before an AttributesToGet
parameter returns results.
sourcepub fn set_attributes_to_get(self, input: Option<Vec<String>>) -> Self
pub fn set_attributes_to_get(self, input: Option<Vec<String>>) -> Self
A JSON array of user attribute names, for example given_name
, that you want Amazon Cognito to include in the response for each user. When you don't provide an AttributesToGet
parameter, Amazon Cognito returns all attributes for each user.
Use AttributesToGet
with required attributes in your user pool, or in conjunction with Filter
. Amazon Cognito returns an error if not all users in the results have set a value for the attribute you request. Attributes that you can't filter on, including custom attributes, must have a value set in every user profile before an AttributesToGet
parameter returns results.
sourcepub fn get_attributes_to_get(&self) -> &Option<Vec<String>>
pub fn get_attributes_to_get(&self) -> &Option<Vec<String>>
A JSON array of user attribute names, for example given_name
, that you want Amazon Cognito to include in the response for each user. When you don't provide an AttributesToGet
parameter, Amazon Cognito returns all attributes for each user.
Use AttributesToGet
with required attributes in your user pool, or in conjunction with Filter
. Amazon Cognito returns an error if not all users in the results have set a value for the attribute you request. Attributes that you can't filter on, including custom attributes, must have a value set in every user profile before an AttributesToGet
parameter returns results.
sourcepub fn pagination_token(self, input: impl Into<String>) -> Self
pub fn pagination_token(self, input: impl Into<String>) -> Self
This API operation returns a limited number of results. The pagination token is an identifier that you can present in an additional API request with the same parameters. When you include the pagination token, Amazon Cognito returns the next set of items after the current list. Subsequent requests return a new pagination token. By use of this token, you can paginate through the full list of items.
sourcepub fn set_pagination_token(self, input: Option<String>) -> Self
pub fn set_pagination_token(self, input: Option<String>) -> Self
This API operation returns a limited number of results. The pagination token is an identifier that you can present in an additional API request with the same parameters. When you include the pagination token, Amazon Cognito returns the next set of items after the current list. Subsequent requests return a new pagination token. By use of this token, you can paginate through the full list of items.
sourcepub fn get_pagination_token(&self) -> &Option<String>
pub fn get_pagination_token(&self) -> &Option<String>
This API operation returns a limited number of results. The pagination token is an identifier that you can present in an additional API request with the same parameters. When you include the pagination token, Amazon Cognito returns the next set of items after the current list. Subsequent requests return a new pagination token. By use of this token, you can paginate through the full list of items.
sourcepub fn filter(self, input: impl Into<String>) -> Self
pub fn filter(self, input: impl Into<String>) -> Self
A filter string of the form "AttributeName Filter-Type "AttributeValue"". Quotation marks within the filter string must be escaped using the backslash (\
) character. For example, "family_name = \"Reddy\""
.
-
AttributeName: The name of the attribute to search for. You can only search for one attribute at a time.
-
Filter-Type: For an exact match, use
=
, for example, "given_name = \"Jon\"
". For a prefix ("starts with") match, use^=
, for example, "given_name ^= \"Jon\"
". -
AttributeValue: The attribute value that must be matched for each user.
If the filter string is empty, ListUsers
returns all users in the user pool.
You can only search for the following standard attributes:
-
username
(case-sensitive) -
email
-
phone_number
-
name
-
given_name
-
family_name
-
preferred_username
-
cognito:user_status
(called Status in the Console) (case-insensitive) -
status (called Enabled in the Console) (case-sensitive)
-
sub
Custom attributes aren't searchable.
You can also list users with a client-side filter. The server-side filter matches no more than one attribute. For an advanced search, use a client-side filter with the --query
parameter of the list-users
action in the CLI. When you use a client-side filter, ListUsers returns a paginated list of zero or more users. You can receive multiple pages in a row with zero results. Repeat the query with each pagination token that is returned until you receive a null pagination token value, and then review the combined result.
For more information about server-side and client-side filtering, see FilteringCLI output in the Command Line Interface User Guide.
For more information, see Searching for Users Using the ListUsers API and Examples of Using the ListUsers API in the Amazon Cognito Developer Guide.
sourcepub fn set_filter(self, input: Option<String>) -> Self
pub fn set_filter(self, input: Option<String>) -> Self
A filter string of the form "AttributeName Filter-Type "AttributeValue"". Quotation marks within the filter string must be escaped using the backslash (\
) character. For example, "family_name = \"Reddy\""
.
-
AttributeName: The name of the attribute to search for. You can only search for one attribute at a time.
-
Filter-Type: For an exact match, use
=
, for example, "given_name = \"Jon\"
". For a prefix ("starts with") match, use^=
, for example, "given_name ^= \"Jon\"
". -
AttributeValue: The attribute value that must be matched for each user.
If the filter string is empty, ListUsers
returns all users in the user pool.
You can only search for the following standard attributes:
-
username
(case-sensitive) -
email
-
phone_number
-
name
-
given_name
-
family_name
-
preferred_username
-
cognito:user_status
(called Status in the Console) (case-insensitive) -
status (called Enabled in the Console) (case-sensitive)
-
sub
Custom attributes aren't searchable.
You can also list users with a client-side filter. The server-side filter matches no more than one attribute. For an advanced search, use a client-side filter with the --query
parameter of the list-users
action in the CLI. When you use a client-side filter, ListUsers returns a paginated list of zero or more users. You can receive multiple pages in a row with zero results. Repeat the query with each pagination token that is returned until you receive a null pagination token value, and then review the combined result.
For more information about server-side and client-side filtering, see FilteringCLI output in the Command Line Interface User Guide.
For more information, see Searching for Users Using the ListUsers API and Examples of Using the ListUsers API in the Amazon Cognito Developer Guide.
sourcepub fn get_filter(&self) -> &Option<String>
pub fn get_filter(&self) -> &Option<String>
A filter string of the form "AttributeName Filter-Type "AttributeValue"". Quotation marks within the filter string must be escaped using the backslash (\
) character. For example, "family_name = \"Reddy\""
.
-
AttributeName: The name of the attribute to search for. You can only search for one attribute at a time.
-
Filter-Type: For an exact match, use
=
, for example, "given_name = \"Jon\"
". For a prefix ("starts with") match, use^=
, for example, "given_name ^= \"Jon\"
". -
AttributeValue: The attribute value that must be matched for each user.
If the filter string is empty, ListUsers
returns all users in the user pool.
You can only search for the following standard attributes:
-
username
(case-sensitive) -
email
-
phone_number
-
name
-
given_name
-
family_name
-
preferred_username
-
cognito:user_status
(called Status in the Console) (case-insensitive) -
status (called Enabled in the Console) (case-sensitive)
-
sub
Custom attributes aren't searchable.
You can also list users with a client-side filter. The server-side filter matches no more than one attribute. For an advanced search, use a client-side filter with the --query
parameter of the list-users
action in the CLI. When you use a client-side filter, ListUsers returns a paginated list of zero or more users. You can receive multiple pages in a row with zero results. Repeat the query with each pagination token that is returned until you receive a null pagination token value, and then review the combined result.
For more information about server-side and client-side filtering, see FilteringCLI output in the Command Line Interface User Guide.
For more information, see Searching for Users Using the ListUsers API and Examples of Using the ListUsers API in the Amazon Cognito Developer Guide.
sourcepub fn build(self) -> Result<ListUsersInput, BuildError>
pub fn build(self) -> Result<ListUsersInput, BuildError>
Consumes the builder and constructs a ListUsersInput
.
source§impl ListUsersInputBuilder
impl ListUsersInputBuilder
sourcepub async fn send_with(
self,
client: &Client,
) -> Result<ListUsersOutput, SdkError<ListUsersError, HttpResponse>>
pub async fn send_with( self, client: &Client, ) -> Result<ListUsersOutput, SdkError<ListUsersError, HttpResponse>>
Sends a request with this input using the given client.
Trait Implementations§
source§impl Clone for ListUsersInputBuilder
impl Clone for ListUsersInputBuilder
source§fn clone(&self) -> ListUsersInputBuilder
fn clone(&self) -> ListUsersInputBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for ListUsersInputBuilder
impl Debug for ListUsersInputBuilder
source§impl Default for ListUsersInputBuilder
impl Default for ListUsersInputBuilder
source§fn default() -> ListUsersInputBuilder
fn default() -> ListUsersInputBuilder
source§impl PartialEq for ListUsersInputBuilder
impl PartialEq for ListUsersInputBuilder
source§fn eq(&self, other: &ListUsersInputBuilder) -> bool
fn eq(&self, other: &ListUsersInputBuilder) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for ListUsersInputBuilder
Auto Trait Implementations§
impl Freeze for ListUsersInputBuilder
impl RefUnwindSafe for ListUsersInputBuilder
impl Send for ListUsersInputBuilder
impl Sync for ListUsersInputBuilder
impl Unpin for ListUsersInputBuilder
impl UnwindSafe for ListUsersInputBuilder
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more