:doc:`SSOAdmin <../../sso-admin>` / Client / list_account_assignments

************************
list_account_assignments
************************



.. py:method:: SSOAdmin.Client.list_account_assignments(**kwargs)

  

  Lists the assignee of the specified Amazon Web Services account with the specified permission set.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/sso-admin-2020-07-20/ListAccountAssignments>`_  


  **Request Syntax**
  ::

    response = client.list_account_assignments(
        InstanceArn='string',
        AccountId='string',
        PermissionSetArn='string',
        MaxResults=123,
        NextToken='string'
    )
    
  :type InstanceArn: string
  :param InstanceArn: **[REQUIRED]** 

    The ARN of the IAM Identity Center instance under which the operation will be executed. For more information about ARNs, see `Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces </general/latest/gr/aws-arns-and-namespaces.html>`__ in the *Amazon Web Services General Reference*.

    

  
  :type AccountId: string
  :param AccountId: **[REQUIRED]** 

    The identifier of the Amazon Web Services account from which to list the assignments.

    

  
  :type PermissionSetArn: string
  :param PermissionSetArn: **[REQUIRED]** 

    The ARN of the permission set from which to list assignments.

    

  
  :type MaxResults: integer
  :param MaxResults: 

    The maximum number of results to display for the assignment.

    

  
  :type NextToken: string
  :param NextToken: 

    The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.

    

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'AccountAssignments': [
              {
                  'AccountId': 'string',
                  'PermissionSetArn': 'string',
                  'PrincipalType': 'USER'|'GROUP',
                  'PrincipalId': 'string'
              },
          ],
          'NextToken': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **AccountAssignments** *(list) --* 

        The list of assignments that match the input Amazon Web Services account and permission set.

        
        

        - *(dict) --* 

          The assignment that indicates a principal's limited access to a specified Amazon Web Services account with a specified permission set.

           

          .. note::

            

            The term *principal* here refers to a user or group that is defined in IAM Identity Center.

            

          
          

          - **AccountId** *(string) --* 

            The identifier of the Amazon Web Services account.

            
          

          - **PermissionSetArn** *(string) --* 

            The ARN of the permission set. For more information about ARNs, see `Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces </general/latest/gr/aws-arns-and-namespaces.html>`__ in the *Amazon Web Services General Reference*.

            
          

          - **PrincipalType** *(string) --* 

            The entity type for which the assignment will be created.

            
          

          - **PrincipalId** *(string) --* 

            An identifier for an object in IAM Identity Center, such as a user or group. PrincipalIds are GUIDs (For example, f81d4fae-7dec-11d0-a765-00a0c91e6bf6). For more information about PrincipalIds in IAM Identity Center, see the `IAM Identity Center Identity Store API Reference </singlesignon/latest/IdentityStoreAPIReference/welcome.html>`__.

            
      
    
      

      - **NextToken** *(string) --* 

        The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.

        
  
  **Exceptions**
  
  *   :py:class:`SSOAdmin.Client.exceptions.ThrottlingException`

  
  *   :py:class:`SSOAdmin.Client.exceptions.InternalServerException`

  
  *   :py:class:`SSOAdmin.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`SSOAdmin.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`SSOAdmin.Client.exceptions.ValidationException`

  