:doc:`GuardDuty <../../guardduty>` / Client / accept_invitation

*****************
accept_invitation
*****************



.. py:method:: GuardDuty.Client.accept_invitation(**kwargs)

  

  Accepts the invitation to be monitored by a GuardDuty administrator account.

  

  .. danger::

        This operation is deprecated and may not function as expected. This operation should not be used going forward and is only kept for the purpose of backwards compatiblity.


  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/guardduty-2017-11-28/AcceptInvitation>`_  


  **Request Syntax**
  ::

    response = client.accept_invitation(
        DetectorId='string',
        MasterId='string',
        InvitationId='string'
    )
    
  :type DetectorId: string
  :param DetectorId: **[REQUIRED]** 

    The unique ID of the detector of the GuardDuty member account.

     

    To find the ``detectorId`` in the current Region, see the Settings page in the GuardDuty console, or run the `ListDetectors <https://docs.aws.amazon.com/guardduty/latest/APIReference/API_ListDetectors.html>`__ API.

    

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

    The account ID of the GuardDuty administrator account whose invitation you're accepting.

    

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

    The value that is used to validate the administrator account to the member account.

    

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

    
    ::

      {}
      
    **Response Structure**

    

    - *(dict) --* 
  
  **Exceptions**
  
  *   :py:class:`GuardDuty.Client.exceptions.BadRequestException`

  
  *   :py:class:`GuardDuty.Client.exceptions.InternalServerErrorException`

  