Publish message to a GCP pub/sub topic

def publish_message(self, message, client):
        """Publish message to a GCP pub/sub topic
         """
        return client.execute_command('publish', {
            'topic': self.data['transport']['topic'],
            'body': {
                'messages': {
                    'data': self.pack(message)
                }
            }
        })