def publish(self, args):
    "\n        #**\n        #* Publish\n        #*\n        #* Send a message to a channel.\n        #*\n        #* @param array args with channel and message.\n        #* @return array success information.\n        #**\n\n        ## Publish Example\n        info = pubnub.publish({\n            'channel' : 'hello_world',\n            'message' : {\n                'some_text' : 'Hello my World'\n            }\n        })\n        print(info)\n\n        "
    if (not (args['channel'] and args['message'])):
        return [0, 'Missing Channel or Message']
    channel = str(args['channel'])
    message = json.dumps(args['message'], separators=(',', ':'))
    if self.secret_key:
        signature = hashlib.md5('/'.join([self.publish_key, self.subscribe_key, self.secret_key, channel, message])).hexdigest()
    else:
        signature = '0'
    return self._request(['publish', self.publish_key, self.subscribe_key, signature, channel, '0', message])
#**
#* Publish
#*
#* Send a message to a channel.
#*
#* @param array args with channel and message.
#* @return array success information.
#**

## Publish Example
info = pubnub.publish({
    'channel' : 'hello_world',
    'message' : {
        'some_text' : 'Hello my World'
    }
})
print(info)
def publish(self, args):
    "\n        #**\n        #* Publish\n        #*\n        #* Send a message to a channel.\n        #*\n        #* @param array args with channel and message.\n        #* @return array success information.\n        #**\n\n        ## Publish Example\n        info = pubnub.publish({\n            'channel' : 'hello_world',\n            'message' : {\n                'some_text' : 'Hello my World'\n            }\n        })\n        print(info)\n\n        "
    if (not (args['channel'] and args['message'])):
        return [0, 'Missing Channel or Message']
    channel = str(args['channel'])
    message = json.dumps(args['message'], separators=(',', ':'))
    if self.secret_key:
        signature = hashlib.md5('/'.join([self.publish_key, self.subscribe_key, self.secret_key, channel, message])).hexdigest()
    else:
        signature = '0'
    return self._request(['publish', self.publish_key, self.subscribe_key, signature, channel, '0', message])