:doc:`LexModelsV2 <../../lexv2-models>` / Client / delete_utterances

*****************
delete_utterances
*****************



.. py:method:: LexModelsV2.Client.delete_utterances(**kwargs)

  

  Deletes stored utterances.

   

  Amazon Lex stores the utterances that users send to your bot. Utterances are stored for 15 days for use with the `ListAggregatedUtterances <https://docs.aws.amazon.com/lexv2/latest/APIReference/API_ListAggregatedUtterances.html>`__ operation, and then stored indefinitely for use in improving the ability of your bot to respond to user input..

   

  Use the ``DeleteUtterances`` operation to manually delete utterances for a specific session. When you use the ``DeleteUtterances`` operation, utterances stored for improving your bot's ability to respond to user input are deleted immediately. Utterances stored for use with the ``ListAggregatedUtterances`` operation are deleted after 15 days.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/models.lex.v2-2020-08-07/DeleteUtterances>`_  


  **Request Syntax**
  ::

    response = client.delete_utterances(
        botId='string',
        localeId='string',
        sessionId='string'
    )
    
  :type botId: string
  :param botId: **[REQUIRED]** 

    The unique identifier of the bot that contains the utterances.

    

  
  :type localeId: string
  :param localeId: 

    The identifier of the language and locale where the utterances were collected. The string must match one of the supported locales. For more information, see `Supported languages <https://docs.aws.amazon.com/lexv2/latest/dg/how-languages.html>`__.

    

  
  :type sessionId: string
  :param sessionId: 

    The unique identifier of the session with the user. The ID is returned in the response from the `RecognizeText <https://docs.aws.amazon.com/lexv2/latest/APIReference/API_runtime_RecognizeText.html>`__ and `RecognizeUtterance <https://docs.aws.amazon.com/lexv2/latest/APIReference/API_runtime_RecognizeUtterance.html>`__ operations.

    

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

    
    ::

      {}
      
    **Response Structure**

    

    - *(dict) --* 
  
  **Exceptions**
  
  *   :py:class:`LexModelsV2.Client.exceptions.ValidationException`

  
  *   :py:class:`LexModelsV2.Client.exceptions.ThrottlingException`

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

  