I'm developing an Android Application and I want to publish a tweet in twitter. My problem is that I don't know how I do to create a tweet in an android app. I searched for information and I find two possible libraries that may be good for tweet content, the libraries are JTwitter and Twitter4J. When I search the information too people say that OAuth it's difficult, and I don't understand nothing of the OAuth.
If it's possible I want to share an image with the tweet, the image can be a Bitmao object?
And, how I do to insert in the predeterminated tweet this image?
Thanks for the time spended
I've personally used Twitter4J with great success. However, there is an easier way to share that will open your app up to many more social networks.
You can use a share
Intent. This blog has a great tutorial that walks you through every step. To include an image, you would use
sharingIntent.putExtra(Intent.EXTRA_STREAM, uri), where
uri is the path of the image on the device (content URI or a direct file path).
The best way that i found to solve this problem is using a sharing intent. In the next link you will have another question with this solution, the only problem is that only work with the official client of twitter.
How to force Share Intent to open a specific app?
So, with that code you will be able to publish the tweet you want using the twitter client.