Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想使用 Trustpilot API 获得评论。我知道我可以通过使用页面参数进行一次获取来获取所有评论。
但是有没有办法过滤日期?我想在某个日期之后运行我的脚本来获取评论?
假设 trustpilot 在 API 中有日期,你可以做的很简单。为您希望显示的评论创建一个新的空列表。将您想要评论的日期转换为毫秒/秒日期。然后继续循环浏览评论,如果转换为毫秒/秒的日期大于您想要的日期,请将其附加到列表中。