:doc:`CloudWatchEvidently <../../evidently>` / Client / stop_launch

***********
stop_launch
***********



.. py:method:: CloudWatchEvidently.Client.stop_launch(**kwargs)

  

  Stops a launch that is currently running. After you stop a launch, you will not be able to resume it or restart it. Also, it will not be evaluated as a rule for traffic allocation, and the traffic that was allocated to the launch will instead be available to the feature's experiment, if there is one. Otherwise, all traffic will be served the default variation after the launch is stopped.

  

  .. 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/evidently-2021-02-01/StopLaunch>`_  


  **Request Syntax**
  ::

    response = client.stop_launch(
        desiredState='COMPLETED'|'CANCELLED',
        launch='string',
        project='string',
        reason='string'
    )
    
  :type desiredState: string
  :param desiredState: 

    Specify whether to consider the launch as ``COMPLETED`` or ``CANCELLED`` after it stops.

    

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

    The name of the launch to stop.

    

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

    The name or ARN of the project that contains the launch that you want to stop.

    

  
  :type reason: string
  :param reason: 

    A string that describes why you are stopping the launch.

    

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

    
    ::

      {
          'endedTime': datetime(2015, 1, 1)
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **endedTime** *(datetime) --* 

        The date and time that the launch stopped.

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

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

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

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

  