diff options
author | Francois Perrad <francois.perrad@gadz.org> | 2011-06-06 19:13:27 +0200 |
---|---|---|
committer | Francois Perrad <francois.perrad@gadz.org> | 2011-06-06 19:13:27 +0200 |
commit | 979a4e0686d753019dca7d18611a9cd862d20eb7 (patch) | |
tree | 0b79e9143d5c564568f8802ff43062ccf18c8f5d | |
parent | add Google Page Speed Online service (diff) | |
download | api-description-979a4e0686d753019dca7d18611a9cd862d20eb7.tar.gz |
add Google Maps services
-rw-r--r-- | services/Makefile | 3 | ||||
-rw-r--r-- | services/googlemaps/Makefile | 29 | ||||
-rw-r--r-- | services/googlemaps/directions.json | 31 | ||||
-rw-r--r-- | services/googlemaps/distancematrix.json | 28 | ||||
-rw-r--r-- | services/googlemaps/elevation.json | 31 | ||||
-rw-r--r-- | services/googlemaps/geocoding.json | 40 | ||||
-rw-r--r-- | services/googlemaps/googlemaps.png | bin | 0 -> 40139 bytes |
7 files changed, 162 insertions, 0 deletions
diff --git a/services/Makefile b/services/Makefile index a64ec10..54d72c2 100644 --- a/services/Makefile +++ b/services/Makefile @@ -3,6 +3,7 @@ SPORE2DOT := perl ../utils/spore2dot.pl check: spore_validation.rx @make -C github check + @make -C googlemaps check @$(VALIDATOR) amazons3.json @$(VALIDATOR) backtweet.json @$(VALIDATOR) backtype.json @@ -33,6 +34,7 @@ png: \ ohloh.png \ twitter.png @make -C github png + @make -C googlemaps png %.png : %.dot dot -T png -o $@ $< @@ -42,4 +44,5 @@ png: \ clean: @make -C github clean + @make -C googlemaps clean -rm *.png *.dot spore_validation.rx diff --git a/services/googlemaps/Makefile b/services/googlemaps/Makefile new file mode 100644 index 0000000..b072b4b --- /dev/null +++ b/services/googlemaps/Makefile @@ -0,0 +1,29 @@ + +VALIDATOR := perl ../../utils/validator.pl --schema spore_validation.rx --description +SPORE2DOT := perl ../../utils/spore2dot.pl + +check: spore_validation.rx + @$(VALIDATOR) directions.json + @$(VALIDATOR) distancematrix.json + @$(VALIDATOR) elevation.json + @$(VALIDATOR) geocoding.json + +test: check + +spore_validation.rx: + wget http://github.com/SPORE/specifications/raw/master/spore_validation.rx + +png: googlemaps.png + +%.png : %.dot + dot -T png -o $@ $< + +googlemaps.dot: \ + directions.json \ + distancematrix.json \ + geocoding.json \ + elevation.json + $(SPORE2DOT) $^ > $@ + +clean: + -rm *.png *.dot spore_validation.rx diff --git a/services/googlemaps/directions.json b/services/googlemaps/directions.json new file mode 100644 index 0000000..2d1d53b --- /dev/null +++ b/services/googlemaps/directions.json @@ -0,0 +1,31 @@ +{ + "version" : "0.1", + "base_url" : "http://maps.googleapis.com/maps/api", + "methods" : { + "directions" : { + "path" : "/directions/:format", + "method" : "GET", + "required_params" : [ + "format", + "origin", + "destination", + "sensor" + ], + "optional_params" : [ + "mode", + "waypoints", + "alternatives", + "avoid", + "units", + "region", + "language" + ] + } + }, + "authority" : "http://github.com/SPORE", + "name" : "Google Maps", + "meta" : { + "documentation" : "http://code.google.com/apis/maps/documentation/directions/", + "module" : "Directions" + } +} diff --git a/services/googlemaps/distancematrix.json b/services/googlemaps/distancematrix.json new file mode 100644 index 0000000..37dd023 --- /dev/null +++ b/services/googlemaps/distancematrix.json @@ -0,0 +1,28 @@ +{ + "version" : "0.1", + "base_url" : "http://maps.googleapis.com/maps/api", + "methods" : { + "distancematrix" : { + "path" : "/distancematrix/:format", + "method" : "GET", + "required_params" : [ + "format", + "origins", + "destinations", + "sensor" + ], + "optional_params" : [ + "mode", + "language", + "avoid", + "units" + ] + } + }, + "authority" : "http://github.com/SPORE", + "name" : "Google Maps", + "meta" : { + "documentation" : "http://code.google.com/apis/maps/documentation/distancematrix/", + "module" : "Distance Matrix" + } +} diff --git a/services/googlemaps/elevation.json b/services/googlemaps/elevation.json new file mode 100644 index 0000000..0e3f029 --- /dev/null +++ b/services/googlemaps/elevation.json @@ -0,0 +1,31 @@ +{ + "version" : "0.1", + "base_url" : "http://maps.googleapis.com/maps/api", + "methods" : { + "elevation" : { + "path" : "/elevation/:format", + "method" : "GET", + "required_params" : [ + "format", + "locations", + "sensor" + ] + }, + "elevation_path" : { + "path" : "/elevation/:format", + "method" : "GET", + "required_params" : [ + "format", + "path", + "samples", + "sensor" + ] + } + }, + "authority" : "http://github.com/SPORE", + "name" : "Google Maps", + "meta" : { + "documentation" : "http://code.google.com/apis/maps/documentation/elevation/", + "module" : "Elevation" + } +} diff --git a/services/googlemaps/geocoding.json b/services/googlemaps/geocoding.json new file mode 100644 index 0000000..9ae201f --- /dev/null +++ b/services/googlemaps/geocoding.json @@ -0,0 +1,40 @@ +{ + "version" : "0.1", + "base_url" : "http://maps.googleapis.com/maps/api", + "methods" : { + "geocode" : { + "path" : "/geocode/:format", + "method" : "GET", + "required_params" : [ + "format", + "address", + "sensor" + ], + "optional_params" : [ + "bounds", + "region", + "language" + ] + }, + "address_lookup" : { + "path" : "/geocode/:format", + "method" : "GET", + "required_params" : [ + "format", + "latlng", + "sensor" + ], + "optional_params" : [ + "bounds", + "region", + "language" + ] + } + }, + "authority" : "http://github.com/SPORE", + "name" : "Google Maps", + "meta" : { + "documentation" : "http://code.google.com/apis/maps/documentation/geocoding/", + "module" : "Geocoding" + } +} diff --git a/services/googlemaps/googlemaps.png b/services/googlemaps/googlemaps.png new file mode 100644 index 0000000..cd92135 --- /dev/null +++ b/services/googlemaps/googlemaps.png Binary files differ |