Automatic Access to Spectral from HC3

Spectral from HC3 automatic access:  PAR  &  UV



   

    Automatic access is a charged service. Please contact us for a quotation

Automatic access to satellite-derived solar radiation database spectral radiation values computed from the satellite derived solar radiation HelioClim-3 version 5 database. Two spectral bands are available: Photosynthetically Active Radiation (PAR) or Ultra-Violet (UV) data. Please  for a quotation and receive your SoDa credentials. This type of access is particularly well-suited for monitoring applications or to launch a large number of requests on a non-regular grid of points.

Automatic access with WGET - with CURL - FAQ

Download examples of scripts :   Unix                 Windows

Download WGET.EXE

   


Warning! It is strongly recommanded to avoid the launch of parallel requests, using the "&" at the end of each wget request line. This would endanger our system.
 

Automatic access with WGET

  1. Subscribe an annual access to spectral radiation values computes from HelioClim-3 Archives service (Contact us)
  2. Download wget.exe in a directory (on Windows - wget is available by default on Unix)
  3. In the same directory, create a text file and copy-paste in a single line the following instruction to test this permanent access to Carpentras, France:

wget -O output.csv --header="soda-user: guest" --header="soda-passwd: guest" "https://api.soda-solardata.com/pub/ ...
spectral_from_hc3_request.php?geopoint=44.083,5.059&elevation=-999&firstday=2012-01-01&lastday=2012-12-31 ...

&duration=h&spectralband=par&horizon=1"

  1. Rename the text file with the .bat extension and double click on it to retrieve the output.csv output file (Windows environment). Or, rename the text file with a .sh extension and run it using >my_script.sh in a Unix environment.

  WGET, in details

Request:
wget -O output.csv --header="soda-user: login" --header=soda-passwd: password" ...
"https://server/pub/spectral_from_hc3_request.php?
geopoint=latitude,longitude&elevation=altitude& ...
firstday=yyyy-mm-dd&lastday=yyyy-mm-dd&duration=time_step&time=time_reference&spectralband=string_spectral_band
&horizon=boolean_horizon"

Inputs:

  • login/password authentication: login and password provided by the SoDa team to access HelioClim-3 within the framework of your subscription. Note that a free permanent automatic access is set up for the site of Carpentras, France, where a Baseline Surface Radiation Network (BSRN) station is available with the login/password guest/guest
  • server: By default, use our load balancer thanks to "api.soda-solardata.com". It will redirect your request on the fastest server available.
  • latitude and longitude: in degrees, with at least 3 digits after comma
  • altitude: in meters. Set "elevation=-999" to let SoDa get the elevation from Nasa SRTM database
  • yyyy-mm-dd: set the first and the last days of the request. The available shortcuts to use for first and last days of the requests are: d, d-x, d+x, m, m-x, m+x, y, y-x, y+x with "x" representing numerical value, "d" = day, "m" = month, "y" = year
  • time_step: "1", "5", "10", "15" (minutes), "h" (hourly), "d" (daily), "m" (monthly)
  • time_reference: "UT" (universal time).
  • string_spectral_band: string corresponding to your spectral band choice: either "PAR" for Photosynthetically Active Radiation data, or "UV" for Ultra-Violet. This information is not case sensitive.
  • boolean_horizon: (optional) "1" (or "0") to take into account (or not) the shadowing effect due to the far horizon.

Outputs for UV data:

  1. Date: format DD-MM-YYYY
  2. Time: format hh:mm
  3. UVA: Irradiation in UV-A (315-400 nm) over the period on horizontal plane (-999 if not data)
  4. UVB: Irradiation in UV-B (280-315 nm) over the period on horizontal plane (-999 if no data)
  5. UV: Irradiation in UV (280-400 nm) over the period on horizontal plane (-999 if no data)

Outputs for PAR data:

  1. Date: format DD-MM-YYYY
  2. Time: format hh:mm
  3. PAR (µmol/m2/s): PAR (400-700 nm) over the period on horizontal plane (-999 if no data)
  4. PAR clear-sky (µmol/m2/s): PAR (400-700 nm) over the period on horizontal plane in cloud-free conditions (-999 if no data)
  5. PAR TOA (µmol/m2/s): PAR (400-700 nm) over the period on horizontal plane at the top of the atmosphere (-999 if no data)
  6. Code: 0: no data, 1: sun below horizon, 2: satellite assessment, 5: interpolation in time, 6: forecast


Automatic access using CURL

You can also automatically retrieve these data using the CURL command. The advantage is to fasten the requests by an approx. factor of 2. Note that all characteristics (inputs and outputs) described in the WGET section are valid for CURL, except that CURL outputs don't have any header.

Request (Windows):
curl -f -s -S -F stations=@stations.txt -o output.csv --header "soda-user: guest" ...
--header "soda-passwd: guest" https://api.soda-solardata.com/pub/spectral_from_hc3_request.php

With the following stations.txt file format:
# Columns:
# id: station name
# latitude and longitude: in degrees, with at least 4 digits after comma
# elevation: in meters. Use -999 to let SoDa get the elevation from Nasa SRTM database.
# time reference: "UT" (universal time)
# duration: "1" (minute), "15" (minutes), "h" (hourly), "d" (daily), "m" (monthly)
# firstday and lastday: first and the last days of the request, expressed as yyyy-mm-dd
# spectral band: string, either 'PAR' or 'UV'. This information is not case sensitive
# horizon: boolean in order to take into account (or not) the shadowing effect due to the
# far horizon in HelioClim-3 version 5 (optional. Default is 0)
#
# id         lat    lon   elevation time duration firstday   lastday   spectralband horizon
Carpentras1  44.083 5.059 -999     UT   15       2017-01-01 2017-01-05 par          1
Carpentras2  44.083 5.059 -999    UT    15       2018-01-01 2018-01-05 uv          0
...