新增素材更新功能
This commit is contained in:
@@ -78,4 +78,28 @@ class DouyinApi:
|
||||
url,
|
||||
'POST',
|
||||
{"json": params or {}}
|
||||
)
|
||||
|
||||
#获取素材消耗
|
||||
async def get_material_cost(self, oauth_id: str, params: any, request_count: int = 3) -> Dict[str, Any]:
|
||||
if not oauth_id:
|
||||
raise RuntimeError('OAuth ID is not set.')
|
||||
url = "https://api.oceanengine.com/open_api/v3.0/report/custom/get/"
|
||||
return await self.request.request_with_token_with_context(
|
||||
oauth_id,
|
||||
url,
|
||||
'GET',
|
||||
{'params': params or {}},
|
||||
request_count=request_count
|
||||
)
|
||||
#获取账户信息
|
||||
async def get_account_info(self, oauth_id: str, params: any) -> Dict[str, Any]:
|
||||
if not oauth_id:
|
||||
raise RuntimeError('OAuth ID is not set.')
|
||||
url = "https://api.oceanengine.com/open_api/2/agent/advertiser_info/query/"
|
||||
return await self.request.request_with_token_with_context(
|
||||
oauth_id,
|
||||
url,
|
||||
'GET',
|
||||
{'params': params or {}}
|
||||
)
|
||||
Reference in New Issue
Block a user