Issues in Downloading EFAS

Hello I’m trying to download EFAS forecast data for 2023. This is the script that I’m using

import cdsapi

c = cdsapi.Client()

c.retrieve(
‘efas-forecast’,
{
‘format’: ‘netcdf4.zip’,
‘system_version’: ‘operational’,
‘originating_centre’: ‘ecmwf’,
‘product_type’: ‘high_resolution_forecast’,
‘variable’: ‘river_discharge_in_the_last_6_hours’,
‘model_levels’: ‘surface_level’,
‘year’: ‘2023’,
‘month’: [
‘01’, ‘02’, ‘03’,
‘04’, ‘05’, ‘06’,
‘07’, ‘08’, ‘09’,
‘10’, ‘11’, ‘12’,
],
‘day’: [
‘01’, ‘02’, ‘03’,
‘04’, ‘05’, ‘06’,
‘07’, ‘08’, ‘09’,
‘10’, ‘11’, ‘12’,
‘13’, ‘14’, ‘15’,
‘16’, ‘17’, ‘18’,
‘19’, ‘20’, ‘21’,
‘22’, ‘23’, ‘24’,
‘25’, ‘26’, ‘27’,
‘28’, ‘29’, ‘30’,
‘31’,
],
‘time’: [
‘00:00’, ‘12:00’,
],
‘leadtime_hour’: ‘72’,
},
‘download.netcdf4.zip’)

However I got the following message:
2024-06-28 16:21:58,468 INFO Welcome to the CDS
2024-06-28 16:21:58,468 INFO Sending request to https://ads.atmosphere.copernicus.eu/api/v2/resources/efas-forecast
Traceback (most recent call last):
File “/g100/home/userexternal/mreale01/.conda/envs/GR-env/lib/python3.8/site-packages/cdsapi/api.py”, line 427, in _api
result.raise_for_status()
File “/g100/home/userexternal/mreale01/.conda/envs/GR-env/lib/python3.8/site-packages/requests/models.py”, line 943, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: for url: https://ads.atmosphere.copernicus.eu/api/v2/resources/efas-forecast

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “download_efas_forecast.py”, line 5, in
c.retrieve(
File “/g100/home/userexternal/mreale01/.conda/envs/GR-env/lib/python3.8/site-packages/cdsapi/api.py”, line 348, in retrieve
result = self._api(“%s/resources/%s” % (self.url, name), request, “POST”)
File “/g100/home/userexternal/mreale01/.conda/envs/GR-env/lib/python3.8/site-packages/cdsapi/api.py”, line 450, in _api
raise Exception(error)
Exception: Resource efas-forecast not found

Could you help me please in fixing this problem?

best

marco

Hi. Were you able to solve this?

Hi,
please use the right credentials. You can copy them from here (please log in first):

Thanks