sc-common-interface 2.8.8__tar.gz → 2.9.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/PKG-INFO +1 -1
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/CommonOa.py +2 -3
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/LiveCommonInterface.py +9 -7
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/PostCommonInterface.py +2 -4
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/PKG-INFO +1 -1
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/setup.py +1 -1
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/McCommonInterface.py +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/Platform.py +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/__init__.py +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/SOURCES.txt +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/dependency_links.txt +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/requires.txt +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/top_level.txt +0 -0
- {sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/setup.cfg +0 -0
{sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/LiveCommonInterface.py
RENAMED
|
@@ -8,7 +8,7 @@ import random
|
|
|
8
8
|
import hmac
|
|
9
9
|
from hashlib import sha1
|
|
10
10
|
import random
|
|
11
|
-
|
|
11
|
+
|
|
12
12
|
|
|
13
13
|
def delete_post(data):
|
|
14
14
|
env = data["env"]
|
|
@@ -167,6 +167,7 @@ def delate_activity(data):
|
|
|
167
167
|
headers = data["headers"]
|
|
168
168
|
activity_id = data["activity_id"]
|
|
169
169
|
url = "%s/api/activity/%s" % (env, activity_id)
|
|
170
|
+
time.sleep(5)
|
|
170
171
|
response = requests.delete(url,headers=headers).json()
|
|
171
172
|
return response
|
|
172
173
|
|
|
@@ -544,7 +545,7 @@ def get_broadcast_list(data):
|
|
|
544
545
|
"pageNum": pageNum,
|
|
545
546
|
"pageSize": pageSize
|
|
546
547
|
}
|
|
547
|
-
print(body)
|
|
548
|
+
# print(body)
|
|
548
549
|
reponse = requests.post(url,headers=headers,json=body).json()
|
|
549
550
|
if name !="":
|
|
550
551
|
name_list = jsonpath(reponse,"$..name")
|
|
@@ -946,12 +947,13 @@ def get_stamp_time(data):
|
|
|
946
947
|
time_type = data.get("time_type","add")
|
|
947
948
|
unit = data.get("unit","minutes")
|
|
948
949
|
# 获取当前 UTC 时间
|
|
949
|
-
now = datetime.now()
|
|
950
|
+
now = datetime.datetime.now()
|
|
950
951
|
if time_type not in {"add", "sub"}:
|
|
951
952
|
raise ValueError("Invalid time_type. Use 'add' or 'sub'.")
|
|
952
953
|
stamp_time = now + datetime.timedelta(**{unit:num if time_type == "add" else -num})
|
|
953
954
|
return int(stamp_time.timestamp()*1000)
|
|
954
955
|
|
|
956
|
+
|
|
955
957
|
def get_line_info(data):
|
|
956
958
|
env = data["env"]
|
|
957
959
|
headers = data["headers"]
|
|
@@ -2453,10 +2455,10 @@ def get_merchant_currency(data):
|
|
|
2453
2455
|
|
|
2454
2456
|
|
|
2455
2457
|
if __name__=="__main__":
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
print(
|
|
2458
|
+
stamp1 = get_stamp_time({"num":5040})
|
|
2459
|
+
print(stamp1)
|
|
2460
|
+
stamp2 = get_stamp_time({"num": 6000})
|
|
2461
|
+
print(stamp2)
|
|
2460
2462
|
|
|
2461
2463
|
|
|
2462
2464
|
|
{sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/PostCommonInterface.py
RENAMED
|
@@ -1068,6 +1068,7 @@ def get_user_conversation_id(data):
|
|
|
1068
1068
|
# param = {"type":"facebook","user_id":vars["user_id"],"party_channel_id":vars["platform_channel_id"]}
|
|
1069
1069
|
print(url)
|
|
1070
1070
|
response = requests.get(url, headers=headers).json()
|
|
1071
|
+
print(response)
|
|
1071
1072
|
|
|
1072
1073
|
conversation_id = jsonpath(response, "$.data.id")[0]
|
|
1073
1074
|
return conversation_id,response
|
|
@@ -1721,8 +1722,5 @@ def edit_message(data):
|
|
|
1721
1722
|
|
|
1722
1723
|
|
|
1723
1724
|
if __name__=="__main__":
|
|
1724
|
-
|
|
1725
|
-
orderNumber, customer_id, res = manual_order(data)
|
|
1726
|
-
print(orderNumber)
|
|
1727
|
-
|
|
1725
|
+
pass
|
|
1728
1726
|
|
{sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface/McCommonInterface.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/requires.txt
RENAMED
|
File without changes
|
{sc_common_interface-2.8.8 → sc_common_interface-2.9.0}/sc_common_interface.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|