code: def _send_message(session, user_id, message=None, image_files=None):
          
          assert any([message, image_files])
  
          attachment_items = None
          if image_files:
              attachment_items = Photo._upload_messages_photos_for_group(session, user_id, image_files)
  
          message_id = session.fetch("messages.send", user_id=user_id, message=message, attachment=attachment_items, random_id=random.randint(1, 10**6))
          return message_id
docs: https://vk.com/dev/messages.send