How to make online products on satellite images: Preparation

How to make online products on satellite images: Preparation

Posted on 15 Dec 2016

Step 1: How to start
Contact us to get your API key and always use it in each query as &APPID={APIKEY}.
http://owm.io/get

Step 2: Setup coordinates of your field
How can you use the visual tool to form a polygon we already wrote here https://owm.io/workouts/post/query-buildere-xamples-how-polygon-can-be-used

Query template
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-121.32,37.65],[-121.32,37.72],[-121.11,37.72],[-121.11,37.65],[-121.32,37.65]]]}}&APPID={APIKEY}

Step 3: Get a list of dates with available images
We will ask an API for searching of all available images for the polygon in our database.
You can setup a cloudiness. If you like to get dates when images had cloudiness less than 40% just add a filter &where=clouds< 40

Query template
http://api.sat.owm.io/api/2.5/search?poly={"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-121.32,37.65],[-121.32,37.72],[-121.11,37.72],[-121.11,37.65],[-121.32,37.65]]]}}&APPID={APIKEY}

Example of the respond:

[
{"date":"2013-12-12","day":"2013-346","time":1386874046,"clouds":0.76,
"sun":{"elevation":27.06930431,"azimuth":160.64830388},
"intersection":100,
"bands":["B2","B3","B4","B5","B7"],
"scenes":["LC80440342013346LGN00"],
"status":"loaded"},

{"date":"2016-04-01","day":"2016-092","time":1459535960,"clouds":0.59,
"sun":{"elevation":51.94210445,"azimuth":143.49839958},
"intersection":100,
"bands":["B2","B3","B4","B5","B7"],
"scenes":["LC80430342016092LGN00"],
"status":"loaded"},
...
]