-
Notifications
You must be signed in to change notification settings - Fork 14
/
query_admin_basic_price.py
38 lines (28 loc) · 1.34 KB
/
query_admin_basic_price.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import logging
import time
from atomic_queries import _query_admin_basic_price
logger = logging.getLogger("query_and_preserve")
# The UUID of user fdse_microservice is that
uuid = "4d2a46c7-71cb-4cf1-b5bb-b68406d9da6f"
date = time.strftime("%Y-%m-%d", time.localtime())
base_address = "http://139.196.152.44:31000"
def query_admin_basic_price(headers):
_query_admin_basic_price(headers=headers)
if __name__ == '__main__':
cookie = "JSESSIONID=823B2652E3F5B64A1C94C924A05D80AF; YsbCaptcha=2E037F4AB09D49FA9EE3BE4E737EAFD2"
Authorization = "eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJmZHNlX21pY3Jvc2VydmljZSIsInJvbGVzIjpbIlJPTEVfVVNFUiJdLCJpZCI6IjRkMmE0NmM3LTcxY2ItNGNmMS1iNWJiLWI2ODQwNmQ5ZGE2ZiIsImlhdCI6MTYyODcwNzMxMCwiZXhwIjoxNjI4NzEwOTEwfQ.4TakdJtnTwHBViZtyI3EH7tZYdd--fJrRKHVoKQzQLY"
headers = {
'Connection': 'close',
"Cookie": f"{cookie}",
"Authorization": f"Bearer {Authorization}",
"Content-Type": "application/json"
}
start_time = time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())
for i in range(330):
try:
query_admin_basic_price(headers=headers)
print("*****************************INDEX:" + str(i))
except Exception as e:
print(e)
end_time = time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())
print(f"start:{start_time} end:{end_time}")