def firefox_starts(): # Authenticate the user resp = requests.get(SERVER_URL + '/push-server-config', timeout=30) resp.raise_for_status() resp = requests.post( SERVER_URL + '/registration', timeout=30, data=json.dumps({"simplePushURLs": {"calls": SP_URL, "rooms": SP_URL}})) resp.raise_for_status()
def firefox_starts(): # Authenticate the user resp = requests.get(SERVER_URL + '/push-server-config', timeout=30) resp.raise_for_status() resp = requests.post( SERVER_URL + '/registration', timeout=30, data=json.dumps({"simplePushURLs": { "calls": SP_URL, "rooms": SP_URL }})) resp.raise_for_status()
def post(self, endpoint, data): return requests.post( SERVER_URL + endpoint, json=data, headers=self.headers, timeout=self.timeout)
def post(self, endpoint, data): return requests.post(SERVER_URL + endpoint, json=data, headers=self.headers, timeout=self.timeout)
def post(self, endpoint, data): return requests.post( SERVER_URL + endpoint, data=json.dumps(data), headers={'Content-Type': 'application/json'}, auth=self._auth())
def post(self, endpoint, data): return requests.post(SERVER_URL + endpoint, data=json.dumps(data), timeout=self.timeout, **self._auth())
def post(self, endpoint, data): return requests.post(URL_SERVER + endpoint, data=data, timeout=self.timeout)
def post(self, endpoint, data): return requests.post(URL_SERVER + endpoint, data=json.dumps(data), timeout=self.timeout)