My apologies that I’ve posted a similar question a month ago and that was closed because I accepted a solution and implemented it, because implementation and getting results was my First Priority. Now my worries I mentioned in that thread have become reality and I am facing problem of Slow because our Client is really big with 3100 open campaigns. I have implemented the RATE_API_LIMIT and able to get all stats successfully but the problem is that it is really slow.
In reality I may have only 10~12 campaigns which belong to our Application but due to no campaigns id in our system I have to get all of them. I tried sorting the campaigns but unfortunately in my current case all campaigns are active and I have to get all the data of all the line items and then for effected date I get the promoted tweets to get the Stats.
My Actual Current Actual Problem:
The Stats end point GET stats/accounts/:account_id/promoted_tweets demands a required attribute of promoted_tweet_ids. To get promoted tweets ids I need to have line_items to get line_items I get campaign_ids and filter those which are open according to current date (via end_time). This reverse order is really slow because my current Advertiser I am getting data for is too big and have all campaigns as opened
** My Actual requirement/request**
Is there any implementation where I can do some like, I just hit some stats API end point and get only the effected promoted Tweets with only date range parameter, and then I can get the line_items and campaigns which are effected ? Sorry for asking this question again but I still am looking for some reasonable solution!
I hope I’ll find some solution out of this discussion and that maybe helpful for others who may have similar scenario.
The few way out I am thinking about. (Ask my advertiser to manually input the campaign Ids in my Application’s Database, which actually belong to my Application.) But I don’t like it because it is not automated
A little same but maybe a little efficient than current solution. Ask my Advertiser to name the campaign having my Application’s name as a part of campaign name.
Twitter please recommend some solution, all I need to get only effected promoted_tweets for a date range.