:doc:`EventBridge <../../events>` / Client / start_replay

************
start_replay
************



.. py:method:: EventBridge.Client.start_replay(**kwargs)

  

  Starts the specified replay. Events are not necessarily replayed in the exact same order that they were added to the archive. A replay processes events to replay based on the time in the event, and replays them using 1 minute intervals. If you specify an ``EventStartTime`` and an ``EventEndTime`` that covers a 20 minute time range, the events are replayed from the first minute of that 20 minute range first. Then the events from the second minute are replayed. You can use ``DescribeReplay`` to determine the progress of a replay. The value returned for ``EventLastReplayedTime`` indicates the time within the specified time range associated with the last event replayed.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/eventbridge-2015-10-07/StartReplay>`_  


  **Request Syntax**
  ::

    response = client.start_replay(
        ReplayName='string',
        Description='string',
        EventSourceArn='string',
        EventStartTime=datetime(2015, 1, 1),
        EventEndTime=datetime(2015, 1, 1),
        Destination={
            'Arn': 'string',
            'FilterArns': [
                'string',
            ]
        }
    )
    
  :type ReplayName: string
  :param ReplayName: **[REQUIRED]** 

    The name of the replay to start.

    

  
  :type Description: string
  :param Description: 

    A description for the replay to start.

    

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

    The ARN of the archive to replay events from.

    

  
  :type EventStartTime: datetime
  :param EventStartTime: **[REQUIRED]** 

    A time stamp for the time to start replaying events. Only events that occurred between the ``EventStartTime`` and ``EventEndTime`` are replayed.

    

  
  :type EventEndTime: datetime
  :param EventEndTime: **[REQUIRED]** 

    A time stamp for the time to stop replaying events. Only events that occurred between the ``EventStartTime`` and ``EventEndTime`` are replayed.

    

  
  :type Destination: dict
  :param Destination: **[REQUIRED]** 

    A ``ReplayDestination`` object that includes details about the destination for the replay.

    

  
    - **Arn** *(string) --* **[REQUIRED]** 

      The ARN of the event bus to replay event to. You can replay events only to the event bus specified to create the archive.

      

    
    - **FilterArns** *(list) --* 

      A list of ARNs for rules to replay events to.

      

    
      - *(string) --* 

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

    
    ::

      {
          'ReplayArn': 'string',
          'State': 'STARTING'|'RUNNING'|'CANCELLING'|'COMPLETED'|'CANCELLED'|'FAILED',
          'StateReason': 'string',
          'ReplayStartTime': datetime(2015, 1, 1)
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **ReplayArn** *(string) --* 

        The ARN of the replay.

        
      

      - **State** *(string) --* 

        The state of the replay.

        
      

      - **StateReason** *(string) --* 

        The reason that the replay is in the state.

        
      

      - **ReplayStartTime** *(datetime) --* 

        The time at which the replay started.

        
  
  **Exceptions**
  
  *   :py:class:`EventBridge.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`EventBridge.Client.exceptions.ResourceAlreadyExistsException`

  
  *   :py:class:`EventBridge.Client.exceptions.InvalidEventPatternException`

  
  *   :py:class:`EventBridge.Client.exceptions.LimitExceededException`

  
  *   :py:class:`EventBridge.Client.exceptions.InternalException`

  