:doc:`Greengrass <../../greengrass>` / Client / get_service_role_for_account

****************************
get_service_role_for_account
****************************



.. py:method:: Greengrass.Client.get_service_role_for_account()

  Retrieves the service role that is attached to your account.

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/greengrass-2017-06-07/GetServiceRoleForAccount>`_  


  **Request Syntax**
  ::

    response = client.get_service_role_for_account()
    
    
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'AssociatedAt': 'string',
          'RoleArn': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* success
      

      - **AssociatedAt** *(string) --* The time when the service role was associated with the account.
      

      - **RoleArn** *(string) --* The ARN of the role which is associated with the account.
  
  **Exceptions**
  
  *   :py:class:`Greengrass.Client.exceptions.InternalServerErrorException`

  