:doc:`ivschat <../../ivschat>` / Client / send_event

**********
send_event
**********



.. py:method:: ivschat.Client.send_event(**kwargs)

  

  Sends an event to a room. Use this within your application’s business logic to send events to clients of a room; e.g., to notify clients to change the way the chat UI is rendered.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/ivschat-2020-07-14/SendEvent>`_  


  **Request Syntax**
  ::

    response = client.send_event(
        roomIdentifier='string',
        eventName='string',
        attributes={
            'string': 'string'
        }
    )
    
  :type roomIdentifier: string
  :param roomIdentifier: **[REQUIRED]** 

    Identifier of the room to which the event will be sent. Currently this must be an ARN.

    

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

    Application-defined name of the event to send to clients.

    

  
  :type attributes: dict
  :param attributes: 

    Application-defined metadata to attach to the event sent to clients. The maximum length of the metadata is 1 KB total.

    

  
    - *(string) --* 

    
      - *(string) --* 

      


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

    
    ::

      {
          'id': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **id** *(string) --* 

        An identifier generated by Amazon IVS Chat. This identifier must be used in subsequent operations for this message, such as DeleteMessage.

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

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

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

  
  *   :py:class:`ivschat.Client.exceptions.PendingVerification`

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

  