ForeMast function cdsDownload #174601
Replies: 3 comments
This comment was marked as off-topic.
This comment was marked as off-topic.
-
|
Thank you for your answer! I have created a .cdsapirc file but where does it have to go? And in what user interface I have to write the commands you have listed? I have not found that ForeMast can directly make use of the .cdsapric file. Thank you again!
Am 25.09.2025 um 04:55 schrieb Aqib Siddiqui:
Most likely the problem is wrong credentials format or the wrong Copernicus service. ForeMast cdsDownload uses the Copernicus Climate Data Store API and it expects your CDS account id and CDS API key to be available to the cdsapi client. Fix it like this
Create a file named .cdsapirc in your home folder with these two lines
url: https://cds.climate.copernicus.eu/api/v2
key: your_username:your_api_key
Replace your_username and your_api_key with the values from your CDS account. Note the key must be username then a literal colon then the api key. Save the file and restrict permissions
chmod 600 ~/.cdsapirc
Make sure you registered the correct service and activated your account via the confirmation email from the Climate Data Store. The api key may be long and not five digits, that is normal.
Quick validate the credentials from your machine using curl
curl -u "your_username:your_api_key" "https://cds.climate.copernicus.eu/api/v2/resources"
If that returns a list of resources your credentials are valid and ForeMast should work. If curl returns an authentication error double check username and api key and that you activated the account email.
If you still see Could not validate login information ensure ForeMast is calling the CDS api not the Copernicus Open Access Hub. If ForeMast has a parameter or config for which service to use set it to cdsapi or the CDS endpoint. If ForeMast accepts a direct key argument you can pass the username and api key as username then a colon then key otherwise rely on the ~/.cdsapirc file.
If you want I can draft the exact .cdsapirc content and a small Python test using cdsapi for you to run
if you find this solution helpfull upvote this and please follow me it boost my confidence
—
Reply to this email directly, view it on GitHub<#174601 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/BAYN6HFM6QCJ5NMKZYFEQQD3UNKRVAVCNFSM6AAAAACHL5QWYCVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTINJQGUZTEOI>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
|
🕒 Discussion Activity Reminder 🕒 This Discussion has been labeled as dormant by an automated system for having no activity in the last 60 days. Please consider one the following actions: 1️⃣ Close as Out of Date: If the topic is no longer relevant, close the Discussion as 2️⃣ Provide More Information: Share additional details or context — or let the community know if you've found a solution on your own. 3️⃣ Mark a Reply as Answer: If your question has been answered by a reply, mark the most helpful reply as the solution. Note: This dormant notification will only apply to Discussions with the Thank you for helping bring this Discussion to a resolution! 💬 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Select Topic Area
Question
Body
I tried to use the ForeMast cdsDownload function but I get the error message "Could not validate login information". I have registered to copernicus and copied the user ID and the Api key (the former has, however, 32 digits instead of 5 shown in the example).
Thank you for your help! Best regards
Beta Was this translation helpful? Give feedback.
All reactions