gpt4 book ai didi

javascript - 如何从推文事件中获取推文 ID

转载 作者:可可西里 更新时间:2023-11-01 02:45:55 25 4
gpt4 key购买 nike

我正在使用 Twitter web-intents / javascript API ,我有点惊讶。我想做的是在一条推文出现后监听一个事件。按照他们的例子:

twttr.events.bind('tweet', function(event) {
// Do something there
});

但是,我想做的是存储推文 ID 或其他一些相关信息。如果我查看 event 对象,data 属性中似乎没有任何相关信息。

是否可以通过监听推文事件获取推文 ID(或有关推文的任何其他详细信息)?

最佳答案

Web Intent events exist as a mechanism to trigger functionality in your page, not a data API.

The tweet event gets fired to indicate that a Tweet has happened, but we don't provide identifying information through the event payload: Intents function on your site without a user authorizing you access to their account, and providing a Tweet ID for an anonymous user's action would implicitly provide you with their identity.

关于javascript - 如何从推文事件中获取推文 ID,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10841752/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com