Hey !
I have an Android app where the user can search on a specific subject, let's take the word "Cats" for example. When the user submits the search I want to find an image similar or on the subjects the searched for. A search engine for images more or less. I want something "easy" to deal with, so I thought about integrating the Google Search API into my app. Let the user search Google, and take the first image that comes up.
However, I haven't found any example and I just need a push in the right direction. If you could give me an example API for my needs, that'd be great.
Apparently the Google Search API never was fully deprecated it's still up and running. It provides JSON data and is easily parsed with Android.
If anyone else needs an image API here's a test search: https://ajax.googleapis.com/ajax/services/search/images?v=1.0&q=searchquery&rsz=8&start=1&imgsz=small|medium
And the JSON reference: https://developers.google.com/image-search/v1/jsondevguide
Related
How do I get the most used or popular tags from the Instagram API? I searched the API but I couldn't find how to do so. I have seen many Android Apps and websites that do that. However, the closest endpoint I found to get the most popular tags is this one https://api.instagram.com/v1/tags/search?q=snowy&access_token=ACCESS-TOKEN.
I can't comment yet, so......You can use GET /tags/tag-name/media/recent to find the most recently posted media with that tag, and larger returns would lead you to the most used. Yes, that is time consuming, but if you've done some research beforehand you should have a narrowed down list of tags. And there is a new Instagram Graph API that looks like it is designed for business information, details at this link: https://developers.facebook.com/products/instagram/. I have not used it, but perhaps it will give you some additional guidance. If you'd like more information and tutorials on the Instagram API, you can check out this wiki link.
I'm trying to make an application based on Google Directions (Maps) API. Basically, I'll develop a mobile app which will tell users where to navigate with their cars and I'll monitor the actual trip (route followed, time, speed etc). Then, I'll need to process the data retrieved in order to display it on a web platform and compute some statistics.
My questions is, which API should I use and how? I've actually searched about this topic but I couldn't find something useful (like a tutorial) regarding this subject, given the fact that I'm new in this domain and I don't know how to begin and what to do.
Thus, I would really appreciate if you can give me some steps that I must follow in order to accomplish this. Also, all types of materials (tutorials, documentations, articles and anything regarding that subject and tips for really beginners) would be very, very helpful for me!
Refer the following link for directions API documentation.
https://developers.google.com/maps/documentation/directions/intro
You can refer the following link for parsing directions.
https://github.com/jd-alexander/Google-Directions-Android
On Location Listener,listen continuosly your current location and store in a list and after the trip is completed,You can use that list that which path that the user as travelled and do your algorithm according to your requirement.
I'm developing an Android app that will do a Google Image Search and return the images to the user in a list. I've looked around on StackOverflow and have run into some problems. First off, I'm a total newbie programmer with only 4 months' worth of programming experience, so I appreciate you guys being patient with me.
I looked through Google Image Search API and I know it's being depreciated and will get shut down someday. Because of this, I don't want to use it. After extensive research on the topic, I don't want to use Bing or another image search service, and I don't want to do a "reverse image search. I just want to use a simple image search via string. I've used this app (https://github.com/tonytamsf/Android-Image-Search) to look at the code, but in all honesty, it's just not helping and it's confusing me more on how to exactly search for an image on Google. Plus, the app won't compile in Eclipse :(
I've also looked around at Google Developer APIs, and I'm not sure if I need to turn on an API key for myself? Still, a bit confused about that. I thought I needed to do a custom search engine, but just by looking at that, I don't think it's exactly what I'm looking for.
Can anyone point me to some resources for this? I would really appreciate it. Thank you!
Just a heads up, but what you're asking is pretty challenging and it sounds like you're just getting started. Here's what I can suggest though:
To get that demo code working in eclipse, I had to right-click the project, click properties, click Android, then check the box for the version of android installed. (I had android 19 installed, and the code was expecting 16, so it was giving up. Tell it to use what you have, which probably is 19). This worked for me after using the git plugin in eclipse to import the project. If you are importing a different way, you may have different issues. * Using git and importing the project is a good skill to have, so if that's unfamiliar territory, take the time to look at that.
Ok, that's the end of what I am sure of. The rest is an educated guess, but I'm sure others can correct me.
Next, if tinkering with that project isn't enough, getting real google image search working will take several skills, especially since the old API is gone. In total you'll need to know:
Java
Android programming
google cloud services
google custom search API
REST
some other libraries to glue the custom search to your app
It's a big chunk there. Currently, it seems the only way to use google's image search is to run a google app engine (you basically set up an online account for google to run a server for you. It does computation and sends messages back and forth for you. You only get a little bit for free each day and then if you want more you have to pay. This is one-way Google earns money. It's not something they let you run on your own computer anymore.). Then you make your android app talk to that server using your new login ID, and the server will take the search term and send back the answers to your android app.
You can get the app engine running and use it in chrome without dealing with android to save yourself time, then add the android part later in the future. Good luck!
I'm building an application that takes the departure and destination address from the user. The company purchased Capture+ from PostCode anyWhere to be used on our website, I now need to build it on Android.
I'm trying to build a layout that would have something like this demo
http://www.postcodeanywhere.co.uk/address-capture-software/try-it-now/
I tried to look for an Android API for that, but didn't find a Java API http://www.postcodeanywhere.co.uk/support/sample-code.aspx
This link shows how to get started with Capture+ , but again only javascript and some html form
https://www.postcodeanywhere.co.uk/address-capture-software/guide/default.aspx?reg=1
I've tried reading about the search dialog http://developer.android.com/guide/topics/search/search-dialog.html
But i'm not sure if it's the right thing, I'm really lost, can anyone help me please ?
I'm on the technical support team here at Postcode Anywhere. With the Capture+ function at the moment it can only be done with the JavaScript snippet provided in the integration process.
We do however have JAVA code samples for all our API calls which you can use to implement the more traditional 'Click to Find' method. All the APIs can be found here:
http://www.postcodeanywhere.co.uk/address-validation/api/
For the UK the APIs that you require are the 'Find' and the 'Retrieve By ID'.
No problem, good to hear you got it working.
The service is intended to be used in this two part method (Find and retrieve). The retrieve by ID is the call where the charge is made. There are restriction on how many 'Finds' that can be used when no 'Retrieves' are made.
If you want to drop me an email of your requirements I can have a look into the best way of doing it?
My email is tomm#postcodeanywhere.com
Cheers
This one is puzzling me...
For my Android application I want to be able to return the current time in any location the user requests (right down to city level). The request itself comes from a voice command, so I cannot use alternative methods.
The most obvious way (so I thought) was to query Google, but I need your brains to help me solve how to extract the data I want please!
In Google, query:
"What's the time in China"
You should see a 'widget' at the top displaying the answer nicely. View the page source and search on 'China' and it's there - I thought great, this is going to be easy!
But...
"What's the time in London"
Although the display in Google appears the same, there is no result for 'London' when searching the source HTML...?
Using Google Chrome, I inspect the element of the 'widget' and can then view the contents I wish to extract in all cases.
So, my questions is firstly, am I missing something obvious (Google don't want us to be able to do this for example)? Or is there a way to 'force' the result to be in the HTML by structuring the query perhaps?
Secondly, is there a way to access the specific 'element container' and return the results to my Android Application?
I thank you in advance...
You should really use an API instead of parsing html.
I guess there are many many API which will give you the time in a given city.
http://www.worldweatheronline.com/time-zone-api.aspx for example (havnt tried it myself)
If you still want to extract data from the google result (which is html), check for html parsers like in this post : Parse HTML in Android