'Send a message to a specified target.'

def send_message(self, message=None, **kwargs):

    from messagebird.client import ErrorException
    targets = kwargs.get(ATTR_TARGET)
    if (not targets):
        _LOGGER.error('No    target    specified')
        return
    for target in targets:
        try:
            self.client.message_create(self.sender, target, message, {'reference': 'HA'})
        except ErrorException as exception:
            _LOGGER.error('Failed    to    notify    %s:    %s', target, exception)
            continue
