From looking at the oauthlib source code it seems the access_token_method
attribute isn't defined in the remote application. The documentation says that it defaults to 'GET'
, but that appears to not be working in your case.
Try adding it explicitly to your remote_app()
definition.
twitter = oauth.remote_app(
'twitter',
consumer_key='xBeXxg9lyElUgwZT6AZ0A',
consumer_secret='aawnSpNTOVuDCjx7HMh6uSXetjNN8zWLpZwCEU4LBrk',
base_url='https://api.twitter.com/1.1/',
request_token_url='https://api.twitter.com/oauth/request_token',
access_token_url='https://api.twitter.com/oauth/access_token',
authorize_url='https://api.twitter.com/oauth/authenticate',
access_token_method = 'GET' # <--- add this line
)