Public and promoted-only tweets via scoped_timeline API


#1

https://dev.twitter.com/ads/reference/get/accounts/%3Aaccount_id/scoped_timeline

The “scoped_to” param value “none” filters the timeline to show only nullcasted (“Promoted Only”) tweets. The “followers” value shows tweets visible to your followers (let’s call them “Public” tweets).

Is there a way to show both types, in the same response? Currently we’re making two API requests, merging and sorting the response, which seems inefficient.


#2

Not at this time. If you wanted to get both, you’ll need to make at least those 2 API calls.


#3

Thank you @jaakkosf!


#4

Hey is there a way to get all promoted tweets for a random user?
I am new to twitter, and the documentation hardly helps… :confused:


#5

For a random user? That user must have given you privileges to interact with his/her ads account. Otherwise you can’t. But if you do have privileges then yes, you can, if you have been whitelisted for access to the Twitter Ads API.


#6

But whether the tweet is promoted or not is public info right?
Anyone can see whether a tweet was promoted or not on the user’s timeline…

does the API provide this info in any way? I just need to identify whether a random user’s tweet was promoted or not, not the commercial stats related to that tweet…


#7

I don’t think you can see on the user’s timeline whether a tweet is promoted or not. If it is a promoted-only tweet then it will not show on the user’s timeline, if it’s just a promoted tweet it will but I don’t think twitter marks it in any way so as to know that that tweet was promoted by the user.

You can request information about a tweet using https://dev.twitter.com/rest/reference/get/statuses/show/%3Aid
I guess you could infer something from the source and scopes properties of the returned object. For example if there is a scopes property like

public 'scopes' => 
    object(stdClass)[381]
        public 'followers' => boolean false

then you would know that that tweet is a promoted-only tweet, because it doesn’t appear to the user’s followers. But I think that’s about all that you can find out.


Is this the right API for pulling my own stats?
#8

Thanks a lot buddy! Helps a lot! :grinning:


#9

You’re welcome! Glad I could help! :slight_smile:


#10