def add_listing_alert(self, intent, type, item_raw_name, blanket=1, craftable=True):
url = Notifications.ITEM_ALERT+ type +'/'+ parse.quote(item_raw_name) + '/Tradable/'
data = {
"user-id": self.cookies['user-id'],
"item_name":type + ' ' + item_raw_name,
"intent":intent,
"blanket":blanket
}
if craftable:
url += 'Craftable'
else:
url += 'Non-Craftable'
headers = Notifications.gen_headers('/classifieds/subscriptions', url, 'PUT')
r = requests.Request('PUT', Notifications.ITEM_ALERT, data=data, headers=headers, cookies=self.cookies)
prepped = r.prepare()
return self._session.send(prepped)
评论列表
文章目录