Google translating companies' names instead of transliterating - google-translate

I am making a multilingual app using Google Translation service. My app mainly consist of financial data.
In my app there is a part where I get list of stock name which all be part of translation. As the stock name is a brand in itself it needs to be transliterate instead of translation. Google is translating all the stocks name instead of transliterating. Before there was a dedicated API for transliteration but after deprecation of API I am unable to do it with Google translation service.

Related

Google search results which matches certain keywords only on newly published websites

I am trying to automate an scraper which search on Google for newly published websites which contain certain keywords. Resulted websites should also belong to two specific countries.
Currently, I am using Google Custom Search API connected to 2 different Google Programmable Search Engines. First search engine is set to only search in United States, and second one only search on Canada.
For obtaining search results, I am sending an API request to Google API endpoint, using next parameters:
https://customsearch.googleapis.com/customsearch/v1?key=${this.apiKey}&cx=${this.searchEngineId}&q=${question}&dateRestrict=d[1]&num=${numResults}&start=${index}&sort=date
However, I have the impression that I am getting pages which are updated last day, rather newly published websites.
Also, I am fetching many duplicates websites when using both search engines. Both search engines are configured for different countries, so I would expect different results from them

How to apply API key to Google Maps Tile server URL?

I want to use Google Maps Tile server URL inside an application.
I'm using the URL
https://mt0.google.com/vt/lyrs=s&hl=en&x={x}&y={y}&z={z}&s=Ga
and it is working fine.
The problem is that I'm not sure how to use my Google Cloud API key for this URL.
I tried adding the API key at the end of the URL:
https://mt0.google.com/vt/lyrs=s&hl=en&x={x}&y={y}&z={z}&s=Ga&key=[MY_KEY]
but I don't see any activity on "Maps JavaScript API" in my Google cloud console. Meaning that the API Key is not being used.
Does this URL need an API Key?
It's working without the Key for now, but I'm afraid it may not work in the long run or it may be illegal to use it without the Key.
Ok, So I spend some time on this and found some solutions for directly using Map Tile Server URL (without any coding required). Here is a summary:
Google Maps:
The URL https://mt0.google.com/vt/lyrs=s&hl=en&x={x}&y={y}&z={z}&s=Ga currently works, but it is illegal to use as it violates Google Maps TOS Section 3.2.4a https://cloud.google.com/maps-platform/terms/#3-license. because it doesn't use an API Key.
There was a service called Google Maps Tile API, but it has discontinued since September 2019 (the API key need to be whitelisted to be able to use this service, and they don't do it anymore since Sep).
So it seems for now there is no easy and simple way to get Tile Server URL from Google Maps.
Bing Maps:
The URL is in the form http://ecn.{subdomain}.tiles.virtualearth.net/tiles/r{quadkey}.jpeg?g=129 where quadkey is a compact representation of variables x, y and z. So doesn't work directly in applications that require URL's that have x,y,z variables.
Azure Maps:
The URL is in the form https://atlas.microsoft.com/map/tile?subscription-key=***&api-version=2.0&tilesetId=microsoft.imagery&zoom={z}&x={x}&y={y}. For different settings see here. The shortcoming of this approach is that currently it cannot be set to show hybrid maps (satellite + street and city names).
MapBox:
The URL is in the form https://api.mapbox.com/styles/v1/mapbox/satellite-streets-v11/tiles/256/{z}/{x}/{y}?access_token=***. You can set the style of the map (currently set to satellite-streets-v11) by choosing the desired value from here and replacing in the URL.
If you want to directly access map tiles, consider Azure Maps. They don't have the restriction that Google Maps has. It's also cheaper. Here are some samples that directly access the tile server: https://azuremapscodesamples.azurewebsites.net/index.html#Third-Party-Map-Controls
Here are some other useful resources:
https://azure.com/maps
https://learn.microsoft.com/en-us/azure/azure-maps/
https://learn.microsoft.com/en-us/rest/api/maps/render/getmaptile

How do i tell Openrefine to fetch some data trough the google and facebook API (Grel)

I have a list of around 500 foundations and companies and i need to fetch more data like address, description, lat long, email or phone number, from the google and FB APIs I have found something more or less like this, but it won't work in OpenRefine, i need some help please.
I think it is possible to do beacause there is an addon called spotlight for spreadsheets that is able to fetch Google URLs and Lat Long https://www.youtube.com/watch?v=Vj1v3QfyrgA&feature=youtu.be
https://maps.googleapis.com/maps/api/place/findplacefromtext/output?parameters/json?input=value&inputtype=textquery&fields=photos,formatted_address,name,rating,email,geometry&key=YOURKEY
I have created the FB and Google places and google staic map API already. I have tried different queries, but it won't work unless it is in GREL
value.parseJson().geonames[0].lng
value.parseJson().geonames[0].geonameId
value.parseJson().geonames[0].lat
From the error "This API project is not authorized to use this API" the first thing to check is that you have enabled the Places and/or Geocoding API in the Google Developer console, and you have setup an API Key and that it is showing as a credential for the Places API and/or the Geocoding API
Next step, take OpenRefine out of the equation and check you can get a simple API call working in your browser - using one of the Google Places API examples:
https://maps.googleapis.com/maps/api/place/findplacefromtext/json?input=Museum%20of%20Contemporary%20Art%20Australia&inputtype=textquery&fields=photos,formatted_address,name,rating,opening_hours,geometry&key=<INSERT YOUR API KEY HERE>
If that gives you the same error, you know the issue is not with OpenRefine.
If you are still having problems in OpenRefine make sure you are creating URLs in OpenRefine that are valid for the appropriate Google API based on the documentation for that API and that you are using the correct API key.

Google Places API doesn't show all locations in custom app

From research I've learnt that Google Maps and Google Places are not the same thing, but can someone confirm this deduction: does that cause the app to not show all the locations that are shown in Google Maps (let's assume because the business owner didn't list it in Google Places)?
You shouldn't expect the Maps API Web Services and the Google Maps website to work in the exact same way at all times. The Google Maps website gathers data from many different sources. Also, the search stack is different. Due to this, you may find differences between the results of these two services, and you should not use Google Maps website results blind eyed as a control group for your Web Services requests. You can find confirmation that Web Services and maps.google.com can show different results in the Google Maps API FAQ at https://developers.google.com/maps/faq#geocoder_differences.

How to get the values from Particular sites?

I am developing such application where I wanted to retrieve some values from the site.
for example here I am developing an finance application.
and I wanted to take the price for the product from the google finance or yahoo finance.
how can we access this value and it will reflect to our DB?
is it possible to get the values from sites?
What you need to do is consume APIs in your application and store the data as needed:
Google Finance APIs and Tools
yahoo-finance-managed

Resources