A Python client library for the Solcast API for photovoltaic power and solar radiation forecasting.
Sign up and find out more at https://solcast.com.au/api/ .
More documentation coming soon...
$ git clone https://github.com/FidFenix/Radiation.git
$ cd Radiation
$ python setup.py install
An API key is required to use the Solcast API. You can sign up for one at https://solcast.com.au
There are multiple ways of providing the API key to solcast-py:
You can set the environment variable SOLCAST_API_KEY
:
$ export SOLCAST_API_KEY=<insert your API key here>
To persist this between sessions, add this line to your .bashrc
(or equivalent).
Alternatively, you can pass the API key as the final positional argument, or the
keyword argument api_key
. For example:
>>> solcast.get_radiation_forecasts(-35, 149, hours=24)
or:
>>> solcast.get_pv_power_forecasts(-35, 149, capacity=2000, api_key='INSERTYOURAPIKEYHERE')