The documentation looks pretty straightforward (assuming you have an API key)
https://maps.googleapis.com/maps/api/timezone/outputFormat?parameters
So, you need to register for a MAP api key. Request JSON, because it's easy to parse in B4A. Use DateTime.now to get a timestamp (and divide by 1000 to convert to seconds), then just call it as you would a normal URL request.
dim job as httpjob
job.initialise("",Me)
dim apikey as string = "supersecretAPIkey"
dim loc as string = "51.52,-0.03"
job.url = "https://maps.googleapis.com/maps/api/timezone/json?location=" & loc & "×tamp=" & ( Datetime.now/1000) & "&key=" & apikey
job.download
You'll get a response back in JSON, that's something like
{
"dstOffset" : 3600,
"rawOffset" : 0,
"status" : "OK",
"timeZoneId" : "Europe/London",
"timeZoneName" : "British Summer Time"
}
Grab it using job.getstring, and then parse the JSON. Something like this
wait for (job) JobDone as HttpJob
if job.success then
dim parser as JSON parser
parser.initialize(job.GetString)
dim timezone as map = parser.NextObject
log("Time zone name is " & timezone.get("timeZoneName"))
end if
However, also think about why and how you need to get this data, and what you're doing with it? For example, if the phone has network connectivity, it will most likely have updated to the correct local time. So as long as your app can get a UTC timestamp from a web service, then you can calculate the difference anyway. It would seem to me that the chief advantage of the Google API is that you can get the name, and you can find out the offset, even if the user hasn't allowed their phone to update time autoamatically - but then what are you using it for? If the user's decided, for instance, to keep their phone set to their home timezone, then using geolocation to find out where they are and display local timestamps might well not be what they want.