Multiple Twitter Accounts using same API Key/Secrets


#1

We have an app that pulls down ads-api data. Usually, our client only has one twitter account. hence, one twitter account, one api key, one process.
Our new client has multiple products/twitter accounts.
Instead of setting-up multiple processes (to pulldown data for each twitter account),
Is it possible to pull-down ads-api data of multiple twitter account using just one API key ?

thanks.
-jerry


#2

Hi @JerryAclan! An app can be used to interact with the Ads API on behalf of many twitter advertising accounts, once the twitter user authorizes the app to do this. So you can use the same app (i.e. the same API key and secret) for as many twitter advertising accounts as you want, or are allowed by your current Ads API access level.

Does this answer your question?


#3

Hi, majoritasdev. thanks for the reply. However, my question is not using one API key on a twitter account’s many advertising accounts. To clarify, I’d like to know if one API key can be used to pull down the data of many advertising accounts from many different twitter accounts/logins. So, basically, using one API key on many different twitter logins.

thanks.
-jerry


#4

Well… you can use the same app (i.e. the same API key) to interact with the Ads API on behalf of many users, i.e. twitter logins. Of course, as long as you implement oAuth and all the users authorize your app to do so.


#5

Hi @JerryAclan,

It’s possible if the “master” account has access to all others accounts. But I don’t really recommend it because you’re gonna exhaust rate limits if you uses the same api keys!

Regads!


#6

Hey, guys. thanks for the replies.
So, it is possible to just use one account/api-key to pull-down data of other twitter accounts.

To manage the rate limits, we will be using asynchronous method to pull down huge amount of data in one web request.

So, one more favor guys, can you direct me, or give me an idea, on how to go about using one api-key to pull-down data of different other twitter accounts. I understand those other twitter accounts has to “approve” the twitter app (apps.twitter.com).

thanks!
-jerry


#7

Hi! Just to be clear, the API key is of the app, not a twitter user account’s.

For the flow, take a look at https://dev.twitter.com/ads/overview/getting-started, especially the section HTTP & OAuth.


#8

@majoritasdev,
yep, the api-key is of the app and not the twitter user account’s credentials. and that’s what we’re currently doing (but only one api-key per twitter user account). what I’d like to do is use one api-key to download the data of multiple twitter accounts. so given:

  • @TwUser1 with and api-key of APIKEY1
  • @TwUser2, @TwUser3, …, @TwUserN

I’d like to use APIKEY1 to access the ads analytic data of @TwUser1@TwUserN

thanks.
-jerry


#9

Hey Hi,

    I have same question as you have about twitter API. Did you get any solution? If yes then can you please help me for solving my problem.

Thank you,

  • Ragini

#10

Hi! Doesn’t this help?


#11

thanks @majoritasdev,
that link you sent help us. The end solution, for our case, is to create a front-end for the clients to interactively grant us the permission we need —which, in effect, allows our API key to be used to download their ads data.

thanks again.
-jerry


#12

hey @RHatamkar,
the solution that we’re going to take is to create a front-end (browser-based) for our client to login with their twitter account to, in effect, grant us permission to download their ads-api data.
you’ve probably have seen these before. Buttons that would say “Please login with your Twitter account”

-jerry


#13

Ok. Thank you all.

-Ragini