redfox-python-sdk 0.7.1__py3-none-any.whl → 0.7.3__py3-none-any.whl

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.
@@ -16,22 +16,38 @@ class TikTokAPI:
16
16
  def search_users(
17
17
  self,
18
18
  keyword: str,
19
- cursor: int = 0,
20
- rid: str = None,
19
+ offset: str = "0",
20
+ count: str = "20",
21
+ follower_count_filter: int = None,
22
+ profile_type_filter: int = None,
23
+ other_pref_filter: int = None,
21
24
  source: str = "搜索 TikTok 账号-SDK",
22
25
  ) -> dict:
23
26
  """
24
27
  TikTok 关键词搜索账号
25
28
 
26
29
  :param keyword: 搜索关键词(必填)
27
- :param cursor: 翻页游标,第一页为 0,每页 +10
28
- :param rid: 数据返回的 rid,翻页时传入,第一页传空
30
+ :param offset: 偏移量,从 0 开始,翻页 +count
31
+ :param count: 每页数量,默认 20
32
+ :param follower_count_filter: 粉丝数筛选:1=0~1K,2=1K~10K,3=10K~100K,4=100K 以上,不传不限制
33
+ :param profile_type_filter: 账号类型筛选:1=认证用户,不传不限制
34
+ :param other_pref_filter: 其他偏好:1=按用户名相关性,不传不限制
29
35
  :return: 搜索结果字典,包含 cursor/hasMore/userList
30
36
  """
31
- data: Dict[str, Any] = {"keyword": keyword, "cursor": cursor}
32
- if rid is not None:
33
- data["rid"] = rid
34
- return self._client.post("/story/api/deepSearch/tk/searchUser", data=data, source=source)
37
+ data: Dict[str, Any] = {
38
+ "keyword": keyword,
39
+ "offset": offset,
40
+ "count": count,
41
+ }
42
+ if follower_count_filter is not None:
43
+ data["followerCountFilter"] = follower_count_filter
44
+ if profile_type_filter is not None:
45
+ data["profileTypeFilter"] = profile_type_filter
46
+ if other_pref_filter is not None:
47
+ data["otherPrefFilter"] = other_pref_filter
48
+ return self._client.post(
49
+ "/story/api/tiktok/ability/searchUser", data=data, source=source
50
+ )
35
51
 
36
52
  def search_videos(
37
53
  self,
@@ -304,13 +304,15 @@ class XiaohongshuAPI:
304
304
  """
305
305
  小红书黑马爆文榜
306
306
 
307
- :param category: 分类(必填)
308
- :param start_date: 开始日期,格式 yyyy-MM-dd(必填),最长为最近 30 天,默认 30 天前
309
- :return: 黑马爆文榜字典
307
+ :param category: 分类(必填),取值如 综合全部、出行代步、医疗保健、
308
+ 时尚穿搭、美味佳肴 等中文分类名
309
+ :param start_date: 榜单日期,格式 yyyy-MM-dd(必填),最长为最近 30 天;
310
+ 后端字段为 rankDate
311
+ :return: 黑马爆文榜列表
310
312
  """
311
313
  return self._client.post(
312
314
  "/story/api/cozeSkill/getLowPowderExplosiveArticle",
313
- data={"category": category, "startDate": start_date},
315
+ data={"category": category, "rankDate": start_date},
314
316
  source=source,
315
317
  )
316
318
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: redfox-python-sdk
3
- Version: 0.7.1
3
+ Version: 0.7.3
4
4
  Summary: RedFox 红狐数据平台 Python SDK — 同步+异步双客户端,自动重试,零配置
5
5
  Home-page: https://redfox.hk
6
6
  Author: RedFox
@@ -383,7 +383,7 @@ result = client.kuaishou.transcript_result(task_id=task["taskId"])
383
383
 
384
384
  ```python
385
385
  # 搜索用户
386
- client.tiktok.search_users(keyword="tech", cursor=0)
386
+ client.tiktok.search_users(keyword="tech", offset="0", count="20")
387
387
 
388
388
  # 搜索视频
389
389
  client.tiktok.search_videos(keyword="AI", count="20", sort_type="0", region="US")
@@ -14,18 +14,18 @@ redfox/endpoints/gpt_image.py,sha256=JZTL6z2g2kV7W0VL8JICWaR-_ZQ5gEpsiQEWUZto3cs
14
14
  redfox/endpoints/hotspot.py,sha256=VRa9apbYeD3p7ORav9jtItexriM8yLil9dkrI44UBBs,2966
15
15
  redfox/endpoints/instagram.py,sha256=kWjCGmjepnMD-vZjW_vMYylerLSEcKaNh4pDjPfhrc4,2916
16
16
  redfox/endpoints/kuaishou.py,sha256=D4_YD3kHYtF9Sn1dek_rNoe5i4eoauyYAsr_kfdY6qQ,4699
17
- redfox/endpoints/tiktok.py,sha256=vyNF4vklJ5WIPIVvfcv9Lsf7sQOrhcAj0pyGEKR1u5w,3042
17
+ redfox/endpoints/tiktok.py,sha256=6i6yZV9H3LgIJ0LeGXPGPnKd1h9MV0T95GYAwmeaVu8,3780
18
18
  redfox/endpoints/tools.py,sha256=lQDs28ozXVzIGcALu4CHYiFfgbAhQaaekIBhPIXTLxM,5879
19
19
  redfox/endpoints/toutiao.py,sha256=E8RPF79pzfu_CFnbEDWqfflPj8joMTkofBcvA7FPn5A,3250
20
20
  redfox/endpoints/twitter.py,sha256=-oHX4jQYDmf_2p1GK3cCacLR1rq2OeHcmbq4hCR-PAw,5369
21
21
  redfox/endpoints/wechat.py,sha256=Rc3uG4kC1gcFW3rKfeHT6BxZCx4U_A1KXLcWPE7DYGE,13083
22
22
  redfox/endpoints/wechat_channels.py,sha256=caedmf85EsbCebVuvIEecavy6kPrVqkeBmSu_Y_zJ0Q,4798
23
23
  redfox/endpoints/weibo.py,sha256=s9feBGEN9hEsh9CL1Po_qx04auLlfw4P1nnTtutQwOU,1514
24
- redfox/endpoints/xiaohongshu.py,sha256=WPf8hLtIJNguG7VgRZ_EQ_OdlsDAX1fy26j2Scv5xUw,12719
24
+ redfox/endpoints/xiaohongshu.py,sha256=v7abvzx21UyH4RkmTdOxiP-19zY5bYek15IkWnzcVw4,12856
25
25
  redfox/endpoints/yiche.py,sha256=x3oN1NQesm9mQ1-T-GMbBNNaPg1KtB0_rwmmVdQqVXg,3139
26
26
  redfox/endpoints/youtube.py,sha256=RXklsFGbA5DMtdlRiLsDwMN6z5vz13xNAlb-u9vou68,3911
27
27
  redfox/endpoints/zhihu.py,sha256=lLPYMv_HpA7L9B8LIrCB_TSUQ7AJzSld6MwfWNuHZxg,1466
28
- redfox_python_sdk-0.7.1.dist-info/METADATA,sha256=SDNoMQhebFiGmcZAiuE2chRmKF7PTFCb369T8gDgUZ8,25326
29
- redfox_python_sdk-0.7.1.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
30
- redfox_python_sdk-0.7.1.dist-info/top_level.txt,sha256=cOIfFv-M-TaEjpiRQy-OygdvvuHeZrlQSoRWMj0DaEM,7
31
- redfox_python_sdk-0.7.1.dist-info/RECORD,,
28
+ redfox_python_sdk-0.7.3.dist-info/METADATA,sha256=54OI9wfWvmrWi4sRS7WQKNm5HurmgZmZxqdXeBvWYW4,25340
29
+ redfox_python_sdk-0.7.3.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
30
+ redfox_python_sdk-0.7.3.dist-info/top_level.txt,sha256=cOIfFv-M-TaEjpiRQy-OygdvvuHeZrlQSoRWMj0DaEM,7
31
+ redfox_python_sdk-0.7.3.dist-info/RECORD,,