lubaina
#1
After the new changes made on January 18 2019, the App Permissions for the Ads API has changed, after this change and even following the process described in the topic “Breaking Changes to App Permissions for Ads API developers” ( re-generating the token and token_secret ). We still receive the “INSUFFICIENT_USER_AUTHORIZED_PERMISSION” error when calling endpoint “https://ads-api.twitter.com/4/ 1” with a oauth1 authentication using.
{‘code’: ‘INSUFFICIENT_USER_AUTHORIZED_PERMISSION’, ‘message’: ‘User 1052444915169484806 is not authorized to make this request. Please have them reauthorize with your client application.’}
The Consumer API keys and Access token/access token secret for the oauth1 are the one provided by “keys and token” tab of the application defined in the Apps section of https://developer.twitter.com/en/apps/ 2 .
Is there anything that should be done to re-enable this API access? How do we get the access back. Please note that we can make an authenticated call however access to ad accounts has been lost and we get the above error.
The app id is 15906487
Your help is much appreciated
Thanks
Lubaina
jrsyo
#2
Hi @lubaina ,
Could you please read the following topic and see if that workaround works for you?
Best,
Shohei
lubaina
#3
Thanks jrsyo for replying. Is it possible to do3-leggedOAuth process in Python instead of twurl?
I tried doing it in Postman but it is giving me this error at step 3 as described here:
jrsyo
#4
@lubaina If you really want to fix the situation ASAP, please consider using twrul to regenerate token and secret. To answer your question, it is possible if you have a complete web application that has callback URL. Otherwise, you should use PIN-based authorization instead (It’s exactly the same thing what twurl does.).
lubaina
#5
Ok I will try that and see how it goes. Please also let me know if this is a permanent problem or will this be fixed?
@lubaina: We will be putting out a permanent fix so that developers who use the credentials directly from the developer portal can regenerate and use those tokens from that UI.
lubaina
#7
@juanshishido I used twurl to authorise the app. I am still getting the following error: code=401 details=[{‘code’: ‘UNAUTHORIZED_ACCESS’, ‘message’: ‘This request is not properly authenticated’}]>
The twurl request returned an oauth_token, oauth_signature, oauth_nonce. What might be wrong? Should I be getting access token and access token secret using twurl. I am still using the token and secret from the portal.
lubaina
#8
Also how long will the permanent fix take?
lubaina
#9
Also when I access ad accounts using twurl, it gives the same error:
twurl -H “ads-api.twitter.com” “/4/stats/accounts”
{“errors”:[{“code”:“UNAUTHORIZED_ACCESS”,“message”:“This request is not properly authenticated”}],“request”:{“params”:{}}}
jrsyo
#10
@lubaina ,
Also how long will the permanent fix take?
We don’t have ETA for it, but will let you know once it’s done. Thank you for your patience.
What commands did you exactly perform? As I mentioned, once you successfully authorized (twurl authorize --consumer-key ${consumer_key} --consumer-secret ${consumer_secret}), your new access token and secret are already in your local file (e.g., ~/.twurlrc in case you’re using Mac OS X). Did you complete PIN-based authorization through your Web browser? If you’re doing it correctly, you should be able to get a URL link from console and get a PIN code there:
Best,
Shohei
lubaina
#11
@jysyo thanks a lot for your help. It worked for me.
@lubaina: I see that the issue the issues are resolved; glad to hear it! Posting this here for visibility. A permanent fix has been deployed.
See the following update to our original announcement.
system
Closed
#13
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.