| Line 21... |
Line 21... |
| 21 |
import logging
|
21 |
import logging
|
| 22 |
from dtr.utils.utils import get_mongo_connection
|
22 |
from dtr.utils.utils import get_mongo_connection
|
| 23 |
|
23 |
|
| 24 |
GCM_URL = "https://android.googleapis.com/gcm/send"
|
24 |
GCM_URL = "https://android.googleapis.com/gcm/send"
|
| 25 |
GOOGLE_API_KEY = "AIzaSyDw1qBnmxtnfR9NqBewryQ-yo3cG2ravGM"
|
25 |
GOOGLE_API_KEY = "AIzaSyDw1qBnmxtnfR9NqBewryQ-yo3cG2ravGM"
|
| 26 |
PENDING_PUSH_NOTIFICATION_URL = "http://45.33.50.227:3001/getPendingNotifications"
|
26 |
PENDING_PUSH_NOTIFICATION_URL = "http://192.168.158.89:3001/getPendingNotifications"
|
| 27 |
PUSH_NOTIFICATIONS_UPDATE_URL = "http://45.33.50.227:3001/updatePushNotification/?"
|
27 |
PUSH_NOTIFICATIONS_UPDATE_URL = "http://192.168.158.89:3001/updatePushNotification/?"
|
| 28 |
headers = {'content-type':'application/json', "authorization":"key=" + GOOGLE_API_KEY}
|
28 |
headers = {'content-type':'application/json', "authorization":"key=" + GOOGLE_API_KEY}
|
| 29 |
aff_url_headers = {
|
29 |
aff_url_headers = {
|
| 30 |
'User-agent':'Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.120 Safari/537.36',
|
30 |
'User-agent':'Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.120 Safari/537.36',
|
| 31 |
'Accept' : 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
|
31 |
'Accept' : 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
|
| 32 |
'Accept-Language' : 'en-US,en;q=0.8',
|
32 |
'Accept-Language' : 'en-US,en;q=0.8',
|