How to register a webhook url in Twitter?



How to register a Twitter Webhook URL in Twitter? I am successful in authorizing my app using application-only authentication. I believe that app-only authentication is required in sending POST Request in

The error I received is " {“errors”:[{“code”:261,“message”:“Application cannot perform write actions. Contact Twitter Platform Operations through"}]}”

My app have access with read and write. There is no notification of limiting my access.

What is the problem here? How can I solve this issue?


Have you been granted access to that API yet as I believe it’s still a request only beta


I have the same problem and my app and its access levels to app is ok! (Read, write, and direct messages)


@Ricardo @mergenearellano just to confirm, have you applied for and been granted whitelisted access to the Account Activity API?


I think so. I received the email that I’ve granted access to Account Activity API and my app is already set to these access levels: Read, write, and direct messages


Thanks for confirming. I’ll see if anyone can look into this further.


Thx Andy! If you need more information about my apps, just ping me…


@Ricardo / @mergenearellano,

Can you provide the company name you entered in the application. We’ll try to find your application and double check the permissions on your app. Thanks!


Hi, what’s up Jon?
The name is Harlio Bots


Thanks for your patience, @Ricardo! Your app should have access now. To confirm, the app with access has a consumer key ending in “WL9.”


Hi Jon!

Yes, my consumer key ends with WL9, but I tried to register the webhook right now and got the same message.


Is the body of your request a properly json encoded string?


I’m sending something like this:


Hey @Ricardo, your app may be experiencing another issue unrelated to this endpoint.

Have you reached out through as mentioned in the error message? You might have also received an email on the account associated with the app. Check your spam folder just in case.


They said that my app is suspended, but I really didn’t understand why it’s suspended if I couldn’t even register the webhook after my account linking’s approval.


I am getting the same issue as @mergenearellano:

Application cannot perform write actions. Contact Twitter Platform Operations

Everything is set up correctly and I have received the email saying my app was granted access to this beta. I looked at the support link but it looks pretty generic and I couldn’t find an option that really addressed the problem. Can I DM someone to get this sorted? Company name would be Tuunio.


Updating this thread with the findings of the investigation with @Ricardo. Thanks for your help in narrowing this down!

Providing user access tokens with OAuth1.0a appears to work around this issue. Developers will need to use OAuth1.0a eventually to send Direct Messages on behalf of a user, anyway.

We’ll continue to investigate the app-only OAuth2 issue.

For internal tracking: CUST-4222


When I try to use a user access token with OAuth 1.0a, I get this error:

  "errors": [
      "code": 214,
      "message": "Webhook URL does not meet the requirements. Please consult:"

Just can’t get past this stage, I’m afraid.

The docs say that a “detailed error message” will be given, but this is about as generic as it gets. I have no idea why the Webhook URL is failing, and there’s nothing in the error to help narrow it down.

I’ve read the securing docs and followed every step in detail, but it’s just not working for me.

I’m worried about repeatedly trying this as the app is in production. Wonder if I can migrate my beta access to a different app ID - any Twitter devs that can advise on that?


@SteveJonesGtr, the error could be from one of the following:

  • Invalid CRC token or response format. I’ll be discussing this in this thread.
  • High latency on CRC GET request. You’re webhook should respond in less than 1 second.
  • Non-200 response code to CRC GET request (i.e. 404, 500, etc).

And, yes, the error message could be better. We’ll provide this as beta feedback.

We can enable a development app. Fill out another request with this form and mention that your production app was already approved. The submissions are reviewed every couple of days.


@joncipriano - thanks for the quick reply and the detailed information - which would be useful in the documentation. I’ve filed the request for the staging version of the app.

My response is the right format, and there is definitely a 200 response. So the only thing that could be failing is the latency - I’m using ngrok as a tunnel to localhost, which seems pretty slow. I’m seeing 370ms on our staging server, so that should eliminate that.

Where is the latency measured from? ie. where are your servers? I’m based in London, and so are my servers, so it might be a bit of a penalty in terms of latency if they are being pinged from California!