You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error shows that the site is blocking your request.
I guess they are using a cookie (or a combination of multiple cookies) to block direct access to the download endpoint.
The download page sets these four cookies:
They're probably used to identify valid requests.
A workaround could be to send a get request to the aforementioned download page to get the cookies to be used in the post request.
Btw: The data quality does seem to be not that great. Especially if I want to build a check comparing electricity production with consumption, storage use and export I do get errors of up to more than 3 gwh per hour.
I just posted in issue #7 how the example in /smard-api)/python-client/ fails.
But why even need a special library if the use case is quit usual.
I simply want to download the file I may get with the download button on the following smard.de-link:
https://www.smard.de/home/downloadcenter/download-marktdaten#!?downloadAttributes=%7B%22selectedCategory%22:1,%22selectedSubCategory%22:1,%22selectedRegion%22:%22DE%22,%22from%22:1658872800000,%22to%22:1659563999999,%22selectedFileType%22:%22CSV%22%7D
Based on the site traffic I found out, that the following url and payload are used:
Usually I should be able to perform this request:
But I receive the following error:
How may this be solved?
The text was updated successfully, but these errors were encountered: