验证对 Twitter API v2 的请求时出现问题

问题描述 投票:0回答:0

我一直收到这个错误: tweepy.errors.Forbidden: 403 禁止 在验证对 Twitter API v2 端点的请求时,您必须使用来自附加到项目的 Twitter 开发人员应用程序的密钥和令牌。您可以通过开发人员门户创建项目。 即使我可以访问 API V2 我在这里查看了这个解决方案:Twitter api version 2 throws Client Forbidden error 我检查了it says it has v2 access

这里是代码:

`client = tweepy.Client(bearer_token=bearer_token)

tweets=client.search_all_tweets(query=handle,start_time=start_time(7),max_results=100)`

注意:我已经使用过 API V2,它工作得很好,我还重新生成了承载密钥

twitter tweepy twitter-api-v2
© www.soinside.com 2019 - 2024. All rights reserved.