【问题标题】:I can't get number of followers of the followers of a specific user using Twitter API V2我无法使用 Twitter API V2 获取特定用户的关注者的关注者数量
【发布时间】:2022-01-11 23:04:32
【问题描述】:

我很难获得特定用户 ID 的关注者的关注者数量。

我从文档中看到,获得它的唯一方法是使用“user.fields”参数,然后访问“public_metrics.followers_count”。

但我正在努力访问“public_metrics”对象,它只是像这样返回 [Object]。我不知道如何从“public_metrics”对象访问“followers_count”。

这些来自文档:

这是终端返回的内容:

【问题讨论】:

    标签: javascript html css api twitter


    【解决方案1】:

    这是标准的 JavaScript 行为。

    使用console.log(JSON.stringify(result))console.debug(result)

    有关一般问题,另请参阅此答案。enter link description here

    【讨论】:

      猜你喜欢
      • 2013-07-01
      • 2012-07-20
      • 1970-01-01
      • 1970-01-01
      • 2021-11-25
      • 2021-04-14
      • 1970-01-01
      • 1970-01-01
      • 2010-12-23
      相关资源
      最近更新 更多