How to use the jpush.common.get_url function in jpush

To help you get started, we’ve selected a few jpush examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github jpush / jpush-api-python-client / jpush / device / core.py View on Github external
def get_aliasuser(self, alias, platform=None):
        """Get appkey alias users.
        """
        url = common.get_url('alias', self.zone) + alias
        params = { 'platform': platform } if platform else None
        info = self.send("GET", url, params = params)
        return info
github jpush / jpush-api-python-client / jpush / report / core.py View on Github external
def get_messages(self, msg_ids):
        url = common.get_url('report', self.zone) + 'messages'
        params = { 'msg_ids': msg_ids }
        messages = self.send("GET", url, params = params)
        return messages
github jpush / jpush-api-python-client / jpush / report / core.py View on Github external
def get_received_detail(self, msg_ids):
        url = common.get_url('report', self.zone) + 'received/detail'
        params = {'msg_ids': msg_ids}
        response = self.send("GET", url, params = params)
        return response
github jpush / jpush-api-python-client / jpush / push / core.py View on Github external
def send_validate(self):
        """Send the notification to validate.

        :returns: :py:class:`PushResponse` object with ``push_ids`` and
            other response data.
        :raises JPushFailure: Request failed.
        :raises Unauthorized: Authentication failed.

        """
        body = json.dumps(self.payload)
        url = common.get_url('push', self.zone) + 'push/validate'

        response = self._jpush._request('POST', body, url, 'application/json', version=3)
        return PushResponse(response)
github jpush / jpush-api-python-client / jpush / device / core.py View on Github external
def get_taglist(self):
        """Get deviceinfo with registration id.
        """
        url = common.get_url('tag', self.zone)
        info = self.send("GET", url)
        return info
github jpush / jpush-api-python-client / jpush / device / core.py View on Github external
def delete_alias(self, alias, platform=None):
        """Delete appkey alias.
        """
        url = common.get_url('alias', self.zone) + alias
        params = { 'platform': platform } if platform else None
        info = self.send("DELETE", url, params = params)
        return info
github jpush / jpush-api-python-client / jpush / report / core.py View on Github external
def get_messages_detail(self, msg_ids):
        url = common.get_url('report', self.zone) + 'messages/detail'
        params = {'msg_ids': msg_ids}
        response = self.send("GET", url, params = params)
        return response
github jpush / jpush-api-python-client / jpush / device / core.py View on Github external
def check_taguserexist(self, tag, registration_id):
        """Check registration id whether in tag.
        """
        url = common.get_url('tag', self.zone) + tag + "/registration_ids/" + registration_id
        info = self.send("GET", url)
        return info