You are browsing a read-only backup copy of Wikitech. The live site can be found at wikitech.wikimedia.org

Nova Resource:Google-api-proxy/Documentation: Difference between revisions

From Wikitech-static
Jump to navigation Jump to search
imported>Kaldari
(more info)
imported>Kaldari
(redundant)
Line 1: Line 1:
'''Google-api-proxy''' provides a static IP for communication with the [https://developers.google.com/custom-search/ Google Custom Search] search API.  
'''Google-api-proxy''' provides a static IP for communication with the [https://developers.google.com/custom-search/ Google Custom Search] API.  


== Usage ==
== Usage ==

Revision as of 23:40, 31 October 2018

Google-api-proxy provides a static IP for communication with the Google Custom Search API.

Usage

  1. Get the Wikimedia Google API key from Kaldari
  2. Use https://google-api-proxy.wmflabs.org/ instead of https://www.googleapis.com/ when interacting with Google's Custom Search JSON/Atom API.

How it works

https://google-api-proxy.wmflabs.org is a Labs web proxy pointing at an instance in the google-api-proxy project with a static IP address. The instance is running an Nginx web server configured as a reverse proxy. All HTTP requests sent to this proxy will be relayed to https://www.googleapis.com and the upstream response will be provided back to the requesting client. Details of the Nginx configuration are available on GitHub.

API keys using this proxy will need to whitelist the IP address 208.80.155.245 in the Google developer console.

Google OCR for Wikisource uses a similar proxy at https://googlevision-api-proxy.wmflabs.org/ that allows access to the Google Vision API.

Tools using the proxy