Skip to content
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

Problem getting app to be allowed in twitter #1

Open
paala opened this issue Jun 4, 2014 · 2 comments
Open

Problem getting app to be allowed in twitter #1

paala opened this issue Jun 4, 2014 · 2 comments

Comments

@paala
Copy link

paala commented Jun 4, 2014

Hello,
When I use var connector = t.connect( _onConnect , _onError , _onAskPin );
to connect to twitter , it redirects me to a webpage to approuve the app.
I click ok, after that, for 0.5 sec the webpage says redirecting back to app then it redirects me to a webpage that cannot be loaded.
In twitter account on apps :No applications have been approved to use your account.

EDIT:

I use:
private var _onError : String->Void;
private var _onAskPin : Void->Void;
private var _onConnect : Void->Void;

then:
t = new HypTwitter( );
t.consumerKey= "vqECwljUP6AxWXRt1pLpTAJsE";
t.consumerSecret= "cCHPUn4yGNsaPO2KW2cq7Tn906K7Kp0fsdUgAEFAFnUZlSEqOr";
var connector = t.connect( _onConnect , _onError , _onAskPin );

Should I define something for _onError, _onConnect?
Thanks

@paala
Copy link
Author

paala commented Jun 4, 2014

Somehow the app manage to appera under my developer account with read write access:
Now if i try to post by:

t.call( REQUEST(
POST ,
HypTwitter.TWEET_UPDATE ,
null,new Params( "status",">>Hello World Twitter from #Haxe )")
)
);

06-04 12:35:30.435: I/trace(3460): HypTwitter.hx:81: call ::: REQUEST(POST,/1.1/statuses/update.json,null,status=%3E%3EHello%20World%20Twitter%20from%20%23Haxe%20%29)
06-04 12:35:30.435: I/trace(3460): HypTwitter.hx:135: consumerKey ::: vqECwljUP6AxWXRt1pLpTAJsE
06-04 12:35:30.435: I/trace(3460): HypTwitter.hx:136: consumerSecret ::: cCHPUn4yGNsaPO2KW2cq7Tn906K7Kp0fsdUgAEFAFnUZlSEqOr
06-04 12:35:30.435: I/trace(3460): OAuth.hx:146: oauth_consumer_key=vqECwljUP6AxWXRt1pLpTAJsE&oauth_nonce=izvDsVkmkBjbBFYUDDCr&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1401874530&oauth_version=1.0&status=%3E%3EHello%20World%20Twitter%20from%20%23Haxe%20%29
06-04 12:35:30.440: I/trace(3460): HypTwitter.hx:138: OAuth oauth_consumer_key="vqECwljUP6AxWXRt1pLpTAJsE", oauth_nonce="izvDsVkmkBjbBFYUDDCr", oauth_signature="9yhRRi4ssGXATSQZcHviCf2BabU%3D", oauth_signature_method="HMAC-SHA1", oauth_timestamp="1401874530", oauth_version="1.0"

06-04 12:35:31.300: I/trace(3460): HypTwitter.hx:171: _onLoader_ioError ::: [IOErrorEvent type=ioError bubbles=true cancelable=false text=HTTP status code 403 errorID=403]

@paala
Copy link
Author

paala commented Jun 5, 2014

When the project is exported appears a line:
Don't forget to add the new Intent filter & data in to yours Manifest.
I didn't override the manifest file and in instructions there is no point I should that.
Am I missing something?
there is a NewIntent that is not allowed I think.

after auth on twitter: the last line in logcat is:
06-05 10:16:43.905: I/trace(31689): HypTwitter_set_callback
this is the trace from:

#ifdef ANDROID

    AutoGCRoot *eval_callback_intent = 0;

    //
        static value HypTwitter_set_callback( value onCall ){
            ALOG("HypTwitter_set_callback" );
            eval_callback_intent = new AutoGCRoot( onCall );
            return alloc_bool( true );
        }
        DEFINE_PRIM( HypTwitter_set_callback , 1 );

    extern "C"{

        JNIEXPORT void JNICALL Java_fr_hyperfiction_HypTwitter_onNewIntent(
                                                                            JNIEnv * env ,
                                                                            jobject obj ,
                                                                            jstring jsIntent_url
                                                                        ){
            ALOG("Java_fr_hyperfiction_HypTwitter_onNewIntent" );

            const char *sIntent_url = env->GetStringUTFChars( jsIntent_url , false );

            val_call1(
                eval_callback_intent->get( ),
                alloc_string( sIntent_url )
            );

            env->ReleaseStringUTFChars( jsIntent_url , sIntent_url );

        }
    }

#endif

The Java_fr_hyperfiction_HypTwitter_onNewIntent doesn't appear in logcat.

Can you share your android manifest ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant