hapijs / hapijs/bell

Twitter auth no longer working

Open
#492 3 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
JavaScript
Stars
616
Forks
210
Avg merge
3m
Merged PRs (30d)
3

Description

### Runtime

Node

### Runtime version

18.17.1

### Module version

13.0.1

### Last module version without issue

N/A, as this is failing due to Twitter changes.

### Used with

_No response_

### Any other relevant information

Free twitter developer account that has access to 1.1 API (that includes OAuth)

### What are you trying to achieve or the steps to reproduce?

Basic twitter Oauth 1.0a example:

> const twitterAuthStrategy = {
name: 'twitter',
scheme: 'bell',
options: {
provider: 'twitter',
password: process.env.BELL_PASSWORD,
clientId: process.env.TWITTER_API_KEY,
clientSecret: process.env.TWITTER_API_SECRET,
isSecure: config.isProduction,
location: config.baseUrl,
},
config:{
extendedProfile: true,
getMethod: 'account/verify_credentials.json?include_email=true',
}
};

### What was the result you got?

You currently have access to a subset of Twitter API v2 endpoints and limited v1.1 endpoints (e.g. media post, oauth) only. If you need access to this endpoint, you may need a different access level. You can learn more here: https://developer.twitter.com/en/portal/product

code: 453

### What result did you expect?

It shouldn't cause twitter to throw 403, because as per official twitter documentation, https://api.twitter.com/1.1/users/show should still work.

Even if additional email "scope" is omitted (so, with the pure basic example that you're providing), result is the same.

So, current plugin should either work for OAuth 1.0a, or it should support Twitter OAuth 2.0.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.