lazyad 0.0.64__tar.gz → 0.0.65__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.

Potentially problematic release.


This version of lazyad might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: lazyad
3
- Version: 0.0.64
3
+ Version: 0.0.65
4
4
  Summary: 基于Python的懒人包-适用于广告投放模块
5
5
  Home-page: https://gitee.com/ZeroSeeker/lazyad
6
6
  Author: ZeroSeeker
@@ -905,3 +905,86 @@ def deactivate_material(
905
905
  json=data,
906
906
  headers=headers
907
907
  )
908
+
909
+
910
+ def get_toutiao_promotion(
911
+ cookie: str,
912
+ user_id: list = None,
913
+ material_id: str = None,
914
+ cdt_start_date: str = None,
915
+ cdt_end_date: str = None,
916
+ start_date: str = None,
917
+ end_date: str = None,
918
+ host: str = default_host,
919
+ page: int = 1,
920
+ page_size: int = 20,
921
+ sort_field: str = "create_time",
922
+ sort_direction: str = "desc",
923
+ data_type: str = "list"
924
+ ):
925
+ """
926
+ 推广-巨量广告-广告 查询
927
+ :param cookie:
928
+ :param material_id: 素材ID
929
+ :param cdt_start_date: 创建时间,例如:2025-07-05 00:00:00
930
+ :param cdt_end_date: 创建时间,例如:2025-08-04 23:59:59
931
+ :param start_date: 数据日期,例如:2025-08-04
932
+ :param end_date: 数据日期,例如:2025-08-04
933
+ :param host:
934
+ :return:
935
+ """
936
+ url = f"https://{host}/Toutiao/Promotion/getList"
937
+ if not user_id:
938
+ user_id = []
939
+ conditions = {
940
+ "search_field":"promotion_name",
941
+ "search_keyword":"",
942
+ "cl_project_id":[],
943
+ "cl_app_id":[],
944
+ "user_id": user_id,
945
+ "media_account_id":[],
946
+ "companys":[],
947
+ "landing_type":"",
948
+ "delivery_mode":"",
949
+ "project_id":[],
950
+ "status_first":"",
951
+ "scene_type":[],
952
+ "strategy_id":[],
953
+ "ad_type":"",
954
+ "learning_phase":[],
955
+ "star_delivery_type":"",
956
+ "star_task_id":"",
957
+ "app_type":"",
958
+ "external_action":[],
959
+ "deep_external_action":[],
960
+ "deep_bid_type":[],
961
+ "material_id": material_id,
962
+ "search_type":"like",
963
+ "combinatorial_id":"",
964
+ "status":"",
965
+ "status_second":"",
966
+ "cdt_start_date": cdt_start_date,
967
+ "cdt_end_date": cdt_end_date
968
+ }
969
+ data = {
970
+ "conditions": json.dumps(conditions),
971
+ "start_date": start_date,
972
+ "end_date": end_date,
973
+ "page": page,
974
+ "page_size": page_size,
975
+ # "total_count": 1,
976
+ # "total_page": 1,
977
+ "sort_field": sort_field,
978
+ "sort_direction": sort_direction,
979
+ "data_type": data_type
980
+ }
981
+ headers = copy.deepcopy(default_headers)
982
+ headers["Cookie"] = cookie
983
+ if host:
984
+ headers["Host"] = host
985
+ return lazyrequests.lazy_requests(
986
+ method="POST",
987
+ url=url,
988
+ json=data,
989
+ headers=headers
990
+ )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: lazyad
3
- Version: 0.0.64
3
+ Version: 0.0.65
4
4
  Summary: 基于Python的懒人包-适用于广告投放模块
5
5
  Home-page: https://gitee.com/ZeroSeeker/lazyad
6
6
  Author: ZeroSeeker
@@ -13,7 +13,7 @@ with open("README.md", "r", encoding='utf-8') as fh:
13
13
 
14
14
  setuptools.setup(
15
15
  name="lazyad",
16
- version="0.0.64",
16
+ version="0.0.65",
17
17
  description="基于Python的懒人包-适用于广告投放模块",
18
18
  long_description=long_description,
19
19
  long_description_content_type="text/markdown",
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes