Error in integrating twitter in android - android

when i run my apps i am getting error
09-14 16:33:52.854: W/System.err(380): 401:Authentication credentials (http://dev.twitter.com/pages/auth) were missing or incorrect. Ensure that you have set valid conumer key/secret, access token/secret, and the system clock in in sync.
09-14 16:33:52.864: W/System.err(380): error - Read-only application cannot POST
I've changed the access to read, write and direct access
but still the above error says read only application.
My apps is not showing the updates is there ant way to refesh the eclipse or application completely ..it is not taking and showing the updates when I run android application.

is there ant way to refesh the eclipse or application completely
To refresh project, you can clean project by Eclipse -> Project -> Clean -> Select project from check box and radio button to "Clean projects selected below" and ok button.
Log shows you are missing something in request, its very obvious.
Your error is understandable but whether you trying to integrate twitter in app using WebView / browser or straight away (which is not recommendable), using any 3rd party library and if yes then which library you using, is unclear.
You can refer these following tutorials available on internet to integrate twitter in your application.
Using only one library twitter4j to handle oAuth and make tweets both
http://blog.blundell-apps.com/sending-a-tweet/
http://automateddeveloper.blogspot.in/2011/06/android-twitter-oauth-authentication.html
Using two or more third party libraries for oAuth and tweeting tasks
http://blog.tarams.com/?p=212
http://www.android10.org/index.php/articleslibraries/291-twitter-integration-in-your-android-application
http://blog.doityourselfandroid.com/2011/02/13/guide-to-integrating-twitter-android-application/,
Thanks,

Related

Cannot get google-services.json file for Google Play Services

I am currently working on updating the Google Login process in my app using google-services 3.0.0 and play-services 9.6.1 and am having troubles getting the required google-services.json file to include in my project.
I am following the setup guide and trying to get the json file from https://developers.google.com/mobile/add?platform=android.
When I pick my app from the dropdown menu I get a 'bad request' error message.
I went ahead through the process anyway, choosing only Google Login for the service but I still get an error when I attempt to download the google-services.json file
This is what is returned when I attempt to download the file
)]}'
{"code":3,"errorSpace":"generic","placeholders":{"trackingId":"123456789"},"status":400,"message":"backend error"}
Looking at the form that was sent in Fiddler, the query string is
["getArtifactRequest",null,"android:my.app.package","2","123456789"]
(After replacing the trackingId and the project Id numbers in these two requests)
Attempting to go back through the process gives me an error stating that the package already exists (Which it does). Other places seem to imply that I could use this method repeatedly as a way to re-generate the json file though.
The app was already listed in the OAuth 2.0 client IDs on the developer console site when I did this. I also went through it a second time for a debug version of the app which was not already created, but I received the same messages and outcome.
Has anyone else seen this issue and found out how to fix it?
After switching projects for a bit and checking back today, I went through the same process as listed and it worked just fine. I haven't changed any settings, so maybe it was a problem on their end for a while. Wish there was something more helpful to say about this, but it just works now.

404 Error when running TicTacToe sample (Android) against sample Google App Engine project (Java)

I set up the Android App and Google App Engine backend as seen in these two projects:
Android Connected App Engine Project
Java App Engine Backend Project
When I click a TicTacToe-field button, which triggers a request I get an 404 error: "Not found"
04-09 23:11:51.115: W/TicTacToe(26247): GetComputerMoveTask: 404 Not Found
04-09 23:11:51.115: W/TicTacToe(26247): Not Found
That is exactly the what https://myappname.appspot.com/_ah/api/ in the browser shows "Not Found".
Here is what I did:
Created an api project on App Engine Console
There created an Android Client Id with com.google.devrel.samples.ttt as package an my debug keys SHA1-fingerprint
There created a Web Client ID
Integrated the Android Project in eclipse. Updated DEFAULT_ROOT_URL in Tictactoe.java to "https://myappname.appspot.com/_ah/api/"
There updated the value of AUDIENCE in ClientCredentials.java by replacing the string "your_web_client_id" with the generated web-client-id from step 3
Integrated the Java backend project in eclipse.There updated the value of application in appengine-web.xml to myappname
Updated the values in /spi/Ids.java to reflect the web-client-id and android-client-id from step 2 and 3
Updated the value of google.devrel.samples.ttt.CLIENT_ID in war/js/render with web-client-id
Deployed the backend to google. Worked great - it opend the https://myappname.appspot.com/ page showing the correct page after deploying (servlet)
Deployed the android app and tried to make a move in TicTacToe. The app crashes.
I think its very suspicious my DEFAULT_ROOT_URL is set to "https://myappname.appspot.com/_ah/api/" in my Android app whereas this pages show just "Not found" in the browser.
Whats going wrong here?
Thanks in advance
Try to test your API at https://your_app_id.appspot.com/_ah/api/tictactoe/v1/ and see if that doesn't do what you want.
Research from this link:https://github.com/GoogleCloudPlatform/appengine-endpoints-tictactoe-android/blob/master/app/src/main/java/com/google/api/services/tictactoe/Tictactoe.java
Lines 60-74
https://github.com/GoogleCloudPlatform/appengine-endpoints-tictactoe-java/blob/master/src/com/google/devrel/samples/ttt/spi/BoardV1.java
Lines 29-31
I suspect you have the API URL wrong, and diving in the code its apparent that the above URL is correct.
No idea where are you getting the instructions for step 4 (in your list), but looking at Setup Instructions in the for the Android project, step 2, what you should do is:
Update the value of DEFAULT_ROOT_URL in src/com/appspot/api/services/tictactoe/Tictactoe.java to point to the location where you are hosting a Tic Tac Toe backend (based off of the Java backend example).
And the location in your case is crearly "https://myappname.appspot.com/".

Getting Error while Sending automatic email on background

Getting error "java.lang.NoClassDefFoundError: javax.activation.DataHandler" while Sending automatic email on background..I have added activation.jar ,additional.jar.mail.jar already ,but getting same error again,,plz tell me proper solution..
Thanks in advance..
The Android SDK makes it very easy to send emails from an application, but unfortunately, that's only if you want to send them via the built-in mailing app. For most situations this works fine, but if you want to send something out and don't want any input/intervention from the user, it's not as easy.
so please follow this link
http://www.jondev.net/articles/Sending_Emails_without_User_Intervention_(no_Intents)_in_Android
Try going to Project -> Properties -> Java Build Path -> Order & Export and ensure Android Private Libraries are checked for your project and for all other library projects you are using.

Unity Facebook SDK v5.1 cannot login on android device

I get the trouble with using Facebook SDK on android. Below is what I have done:
I'm using Facebook sdk 5.1.0 and Unity version is 4.3.4
In Assets\Facebook\Editor\android\FacebookAndroidUtil.cs, I add
System.Environment.GetEnvironmentVariable("HOMEDRIVE") in line 62
so that "Debug Android Key Hash" can be generated.
I using C# to type the main script, in "Awake()" I add
FB.Init(SetInit, InitCallback);. It just like the tutorial from
developers.facebook.com, and enable is give out "true". (I think
that mean FB.init() is success.)
After that, I build up a GUI button for log in. I have try FB.Login("basic_infos", AfterLogin);, FB.Login("publish_actions", AfterLogin); and FB.Login("email", AfterLogin); , both the FB.isLoggedIn is false on android device.
Actually I can log in on unity environment using "User Access Token". On android device, after I press the Login button, it give out a permission and then I press "OK", nothing happen...(FB.isLoggedIn still false)
Anyone can give a help? I get the trouble a few week already...
p.s. My English is not good, please let me know if you don't understand.

500 Server Error using Python

Please bear with me as I am a complete noob and trying to create a database for my app using App Inventor.
According to Google App Launcher, I have successfully created my app. However, when I load mcdougaltextspeak.appspot.com into my browser, I get the following message:
Error: Server Error
The server encountered an error and could not complete your request.
If the problem persists, please report your problem and mention this error message and the query that caused it.
I am following the directions provided on http://appinventorapi.com/program-an-api-python/ and I'm sure my issue is because I am not correctly modifying the default app.ymal file
Here's what I have according to the directions:
application: textspeakedtech597
version: 1
runtime: python27
api_version: 1
threadsafe: true
handlers:
- url: /images
static_dir: images
- url: .*
script: main.py
I initially just changed myapp to mcdougaltextspeak, however I got a message that I needed to modify the code for python 2.7 according to this site:
https://developers.google.com/appengine/docs/python/python25/migrate27
This site also included modifications for other things, so I am wondering if my error stems from this. The directions do not make note of modifying any other code. Do I need to modify/add the code that appears on the migrate to python 2.7 page (see above link) and if so where does it go.
My app is stuck without a location to hold data.
Any advice on how to proceed is greatly appreciated.
Have you actually created an app on https://appengine.google.com?! You need to do that first, then your app.yaml should contain the appid that you have created i.e. application: mcdougaltextspeak & not what it is in the tutorial.
After you've edited the app as you want, you must then deploy the app to the Google App Engine Servers (refer to the GUI deploy). You would get detailed logs when deploying, which would tell if the deployment was successful or not.
After deploying, you can then goto https://mcdougaltextspeak.appspot.com & play around with your online app. If you still get errors, check https://appengine.google.com/dashboard?&app_id=mcdougaltextspeak for the logs & report them here.

Categories

Resources