Introduction

The Frogcast API provides an easy way to integrate your forecast data with any external system. The API closely follows REST semantics, uses JSON to encode objects, and relies on standard HTTP codes to signal operation outcomes.  

All API documentation below is specifically generated for

Authentification

Frogcast uses simple token-based authentication. Your API token carries the same privileges as your user account, so be sure to keep it secret!
You can authenticate to the API by providing your API token in the HTTP authorization token header. All API requests must be authenticated and made over HTTPS.

Your personal token is

Here's a example of what should set in your header :

Authorization: token 

Forecasts

Retrieving forecasts with the API is very straight forward.
In this section, you'll get ready-to-go examples in Python, JS and CURL.

To retrieve your latest forecast for , you must make a GET request to the following URL :

https://api.frogcast.com/api/v1/forecast/

There are different parameters to customize your query :

data_format (str) from the list below:
  • split (default): orginal format of the api
  • records: fully detailed record with name of field ans value for each time step
  • tight: tight version of the data that can be used for data vizualisation
precision (int):
  • default = 2
horizon (int):
  • default = 21600 ie 15 days
fields (str):
  • default is all fields
  • you can specify the list of fields separated by a ',' for example: ghi_p20,ghi_p80
time_step (int):
  • default = 1
  • interval (in minutes) between each forecast series
date_time_format (str):
  • default is in ISO 8601 UTC format, like "2022-01-01T00:00:00Z"
  • you can also specify "time_stamp" to get unix time stamp
time_stamp_unit (str):
  • to be specified only if the unix time stamp format is requested
  • default is "s" for get unix time stamp in seconds, but you can specify "ms" to get your data in milliseconds

Here is an example in Python :

import requests

parameters = {'horizon':2880}

requests.get(url=url,params=parameters,headers=headers).json()

Here is an example in JS :

var myInit = { method: 'GET', headers: myHeaders }; 

fetch(myRequest,myInit)
  .then(response => response.json())

Here is an example in CURL :

Weather fields

Short name

Long name

Category

All weather variables are associated with percentiles (or quantiles) ranging from 10 to 100.
So you can fetch all the quantiles of any variable.

Example for temperature : t2m,t2m_p10,t2m_p20,t2m_p30,t2m_p40,t2m_p50,t2m_p60,t2m_p70,t2m_p80,t2m_p90

Try it!

URL

https://api.frogcast.com/api/v1/forecast/

Headers

QUERY PARAMETERS

fields:

data_format:

split

precision:

horizon:

time_step:

Results

{}