Subscribe to account activity

Frequently Asked Questions

General

What is going on with User Streams, Site Streams, legacy DM endpoints, and Account Activity API - Standard beta DM only product?

We first announced the deprecation of these products in December 2017. At the time, we announced a 6-month deprecation window ending June 19th, 2018. In May, we released the standard and premium API replacement for these endpoints: Account Activity API. At the same time, we announced an extended deprecation window to August 16th, 2018.

Since May, we have sent several emails to impacted developers, posted reminders in our forums, and shared several Tweets from @TwitterAPI. If you did not receive any of these announcements, we recommend you take a look at our guidance on how to best stay informed for any future notification.

We strongly recommend that you read this recent announcement for more details.

User streams and Site streams:

  • User Streams and Site Streams have been replaced by improved products such as Account Activity API. Both products were retired on August 23rd, 2018.
  • If you haven't already, please review our migration guide.
     

Legacy DM endpoints:

  • The legacy Direct Message endpoints were retired on September 17th, 2018 and have been replaced by new DM endpoints and the Account Activity API. The replacements and migration guides have been generally available for months.
  • If you haven't already, please review our migration guide.
  • We also released a feature on the new POST direct_message/event/new that allows developers to respond to messages they receive, up to 5 times, within 24 hours to make sure users posting via the API can always respond to a message they receive.
     

Account Activity API DM-only endpoint:

  • Now that a version of the Account Activity API that delivers a full set of activities is generally available, the beta that delivered only Direct Messages was retired on August 16th, 2018.
     

How do I identify which product tier is best for me?

Please read through our Account Activity API Overview page to learn more about the differences between the Premium options and the Enterprise option. 
 

What is the difference between a Premium environment and an Enterprise webhook?

There is no difference. Each Premium environment will have its own webhook_id.
 

I need a development, staging and production environment for Account Activity API, is this possible?

Yes! With the paid tiers of Account Activity API (Paid Premium and Enterprise), it's possible to register multiple webhook URLs and manage subscriptions separately for each through the API methods. Additionally, multiple client apps may be whitelisted to maintain authorization for your current authorized users.
 

Do you have any step-by-step guides on how to get set up with the Account Activity API?

As a matter of fact, we do!

  • If you are migrating from Site Streams, User Streams, or the DM API, please check out our Migration introduction page.
  • If you are just getting started, we recommend that you visit our Getting started with webhooks guide
  • Follow along with our Twitter Dev supported scripts: 

Is there a way to recover data if our system goes down for a period of time?

With the paid tiers of Account Activity API (Paid Premium and Enterprise), our system will retry to send the activities to you a few times over a five minute period. If your system does not respond within that five minute period, then the activity will be lost.  After 5 minutes, other REST endpoints can be used to recover data within 7 days.

We suggest that you use your different webhooks, or environments, as a redundancy tool to ensure that you don't miss any activities if one of your systems goes down.
 

What authentication do I have to use with the Account Activity API?

The authorization methods required for Account Activity API is described per method in the API reference pages. If you are just starting out with Twitter authentication, we recommend that you read through this section.

What is a challenge-response check (CRC)?

The Account Activity API challenge response check is a security feature put in place to ensure that the Account Activity API’s activities are being sent to the proper developer. It also can be used by developers to ensure that the data that they are receiving is coming from Twitter. Please visit our page Securing webhooks for more details.
 

Will I get duplicate activities if subscribed to users that are interacting with each other?

Yes.  If your web app has active subscriptions for User A and User B, and User A mentions User B in a Tweet, there will be two POST activities sent to the registered webhook.  Each activity will have an indicator of "for_user_id" to show which subscription the activity belongs to.

Enterprise

How can I whitelist my app or check if my app is already whitelisted?

To manage the Twitter apps that you have whitelisted for access via the Enterprise APIs, please reach out to your account manager with your app ID. You can find your app ID by navigating to the "Apps" page in the developer portal.
 

If I have access to three webhooks, can I use three webhooks for each of the apps that I have whitelisted for enterprise use?

The webhook limit is set on the account level, not the app level. If you have access to three webhooks and two apps whitelisted for enterprise use, you can use two webhooks on one app and the third on the other app, but not three on each app. 

Premium

I already have access to the developer portal, how do I sign up for the Premium Account Activity API?

Once you've logged into your developer portal and navigated to the "Dev environments" page, you can 'Create a dev environment' and add your environment name and Twitter app to start using the Premium Account Activity API.
 

How long will it take to have my Twitter developer account approved?

We continue to work through the applications as quickly as we can. Hang tight - we are just as excited to see what you are going build!
 

How much does the Premium Account Activity API cost?

You can learn more about the different pricing and access levels on our Premium Account Activity API pricing page.
 

How many apps can I use with the Premium Account Activity API?

You can use one Twitter app per dev environment (aka webhook) when using the Premium Account Activity API. That means that you can only have one app with the Sandbox tier, and two apps if you are using the Paid Premium tier.
 

Can I transfer my Premium Account Activity API access to a different app?

While you can change the Twitter app that is utilizing your Premium Account Activity API webhook(s), you have to delete the environment and create a new one to make a transfer.
 

Where does :env_name come from?

You can find your :env_name, or environment name, within the "Dev environments" page. 
 

I need more than 250 user subscriptions! What do I do?

Please apply for our Enterprise access by applying here.
 

How do I downgrade from Paid Premium?

Adjusting your premium tier can be done in the developer dashboard under ‘Manage Subscriptions’. Note that you must downgrade your subscription before the monthly renewal date.  See our Billing FAQ for more.
 

I have a question that hasn’t been answered in the documentation.

Please check our forums to see if your question was answered there. If you still can’t find your answer, please submit a post to the forum.

 

Error troubleshooting guide

Code 32

  • Premium - Make sure you have a developer account, have established a dev environment for the Account Activity API, and are using the proper environment name and app tokens. 
  • Enterprise - Make sure the app tokens that you are using belong to an app that has been whitelisted for use of Enterprise products.
  • Make sure you are using the proper authentication method. 
    • If user context, include the consumer key and secret of the whitelisted app and the access tokens of the user you are trying to make a request on behalf of. 
    • If app only, make sure you are either using the bearer token or a consumer key and secret of the app that is whitelisted for use of the product. 
       

Code 200 - Forbidden

  • Premium - Make sure that you have an approved developer account before you try to make a request to the API. You can apply here.
  • Enterprise - Make sure that your account manager has set you up with access to the Account Activity API.
  • Make sure you have set up your URI properly. This error can trigger if you have entered the incorrect URI in your request.
     

Code 214 - Webhook URL does not meet the requirements.

Code 214 - High latency on CRC GET request. Your webhook should respond in less than 3 seconds.

  • This means that your server is slow. Make sure that you are responding to the CRC within 3 seconds.
     

Code 214 - Non-200 response code during CRC GET request (i.e. 404, 500, etc).

  • Your server is down. Make sure that your server is running properly.
     

Code 214 - Too many resources already created.

  • Enterprise - You have already used all of your webhooks. Use the GET account_activity/webhooks endpoint with each of your whitelisted apps to identify where your webhooks are distributed. 


Code 261 - Application cannot perform write actions. 

  • The app that you are using with the API does not have the proper permission level set for its access token and access token secret. Please navigate to the 'Keys and tokens' tab on the Twitter apps dashboard and check the permission levels assigned to your access token and access token secret. If it is set to anything other than 'Read, write and Direct Messages,' then you are going to have to adjust the settings under the 'Permission' tab and regenerate your access token and access token secret to apply the new settings.