Skip to content

Latest commit

 

History

History
87 lines (47 loc) · 2.23 KB

File metadata and controls

87 lines (47 loc) · 2.23 KB

US-MINES-API DOCUMENTATION

All requests should begin with

or if you're testing it locally:

REQUESTs FOR MINES

GET

  1. all available materials:
  • /mines/materials
  1. all mines regardless of materials (default radius is 200 miles):
  • /mines/@{longitude},{latitude}
  1. Get mines by material and gps coordinates within a particular radius:
  • /mines/{material}/@{longitude},{latitude},{radius}
  1. Get One Mine by Id
  • /mines/{id}

Examples:

REQUESTs FOR LANDFILLS

GET

Similar to Mines but much simpler since there's no material filter.

  1. Get all landfills by latlng (default radius is 200 miles):
  • /landfills/@{longitude},{latitude}
  1. Get mines by material and gps coordinates within a particular radius
  • /landfills/@{longitude},{latitude},{radius}
  1. Get One Landfill by Id
  • /landfills/{id}

Examples:

NOTES:

  1. Validation:

Material cannot contain non-characters and should be separated by "+".

The longitude, latitude, and radius are separated by a comma.

Longitude must be negative and latitude and radius must be larger than 0.

Longitude and latitude should also be in their acceptable range (-180 to 180, -90 to 90, respectively)

  1. Tips:

GPS Coorditates for cities in United States are:

  • Latitude: from 19.50139 to 64.85694
  • Longitude: from -161.75583 to -68.01197 .

All Search Results include an unique ID of each record and are sorted based on distance from nearest to furthest.

Geospatial Queries will return results sorted based on distance, from nearest to furthest. Radius is optional and the default is 200 miles.