(host, api, data, cookie)
| 44 | |
| 45 | |
| 46 | def sentRequest(host, api, data, cookie): |
| 47 | print(cookie, api, data) |
| 48 | xs_xt = getXs(cookie, api, data) |
| 49 | print(xs_xt) |
| 50 | headers['cookie'] = cookie |
| 51 | headers['X-s'] = xs_xt['X-s'] |
| 52 | headers['X-t'] = str(xs_xt['X-t']) |
| 53 | |
| 54 | url = host + api |
| 55 | |
| 56 | return requests.post(url=url, data=json.dumps(data, separators=(",", ":")), headers=headers) |
| 57 | |
| 58 | |
| 59 | def DoApi(param, cookie): |