-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CORS header? #8
Comments
If you get a 400 Error you are not logged in at all, which means you have no OAuth Token. Are you sure you get a valid token before you configure/use ngTwitter? |
@saimon24 How i can get valid Token? When i complete auth i got access_token and access_token_secret , those are same credentials as in apps.twitter.com in Dashboard XMLHttpRequest cannot load https://api.twitter.com/1.1/statuses/home_timeline.json?count=5. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://local.regrem.com' is therefore not allowed access. The response had HTTP status code 400. |
I am also have the same issue, i copied the Consumer Key (API Key), Consumer Secret (API Secret) and the Access Token and it did not work |
@saimon24 I have the same problem. The response had HTTP status code 400. Do we need token object with oauth_token and oauth_token_secret or third parameter must be oauth_token? In the both version this is not working. |
I did a little of debugging through the source code and oauth_token and oauth_token_secret were undefined so i initialized them like this: then i would call: $twitterApi.configure(clientId, clientSecret, token); now the oauth_token and oauth_token_secret are defined but it still shows me the same error |
@botezalexandru I agree with you. Maybe javascript connection with Twitter without backend is not available - https://twittercommunity.com/t/access-control-allow-origin/7253/24 ? 😕 |
@botezalexandru Hey, Did you figure it out eventually ? |
@liadlivnat no, i haven't |
@saimon24 : Your service just does not work ... I did the same thing as @botezalexandru (I went to same conclusion about token being an hash) and the preflight request does not contain any Authorization header as it should be (as far as I understand). Using this :
does not work ... I got the same error than @robinvanb. |
Having the same issue:
I noticed that oauth_token="undefined"; is that normal? |
I saw the other issue that was closed about the CORS header but I simply cannot seem to get this to work.
I'm using the consumer key / secret and the access token / access secret from the OAuth Tool of Twitter to configure
$twitterApi
but I keep getting the HTTP 400Also there are many discussion topics about Twitter not supporting CORS: https://twittercommunity.com/t/access-control-allow-origin/7253/19
Do you have any idea what to do?
The text was updated successfully, but these errors were encountered: