riigikogu-kantselei / api

Public issue tracker for Open data API at the Chancellery of the Riigikogu
https://api.riigikogu.ee/
GNU General Public License v3.0
10 stars 0 forks source link

Downloading public files responds with 403 Forbidden #13

Closed moll closed 5 years ago

moll commented 5 years ago

Hey,

I followed the links from a collective-address to a public file referenced in it. I am able to get the file's metadata, but not its contents. For example https://aavik.riigikogu.ee/api/files/882e0370-4730-426f-bf6a-2b4033ece138 responds fine, but https://aavik.riigikogu.ee/api/files/882e0370-4730-426f-bf6a-2b4033ece138/download doesn't. In fact, it seems no matter the UUID, the /download URL is off limits.

Followed the docs in https://aavik.riigikogu.ee/swagger-ui.html#/Failid/downloadFileUsingGET.

janesmae commented 5 years ago

Hello. This feature is currently not being implemented for the public API demo service. Only metadata is being provided via the Public API demo.

moll commented 5 years ago

Is there an ETA for that? What's keeping the "demo" from becoming "production ready"?

For the record, I found https://www.riigikogu.ee/download/:id to be an alternative for downloading documents.

janesmae commented 5 years ago

The current API demo uses a different database (not live data, up to a month old). It has to be updated regularly. The API will go live soonish (exact date and time is still unclear at this moment as it's functionality and backend logic is being tested constantly and we still have some issues to solve in those areas).

moll commented 5 years ago

Gotcha. Thanks. Rahvaalgatus (https://rahvaalgatus.ee/) will start monitoring initiatives daily or hourly via the API in the next couple of days, so the quicker it goes live or is updated, the better for us and citizens. :)

infokujur commented 5 years ago

@janesmae - kas oleks võimalik seda koopiat kuidagi kiiremini tekitada? Meil on ca 3000 inimest e-kirja listis, kes on tellinud endale teavitused. Nad ei soovi tn endale kuu aja vanust teadet.

infokujur commented 5 years ago

@janesmae - Kas nüüd on selle staatus muutunud? https://github.com/okestonia/opendata-issue-tracker/issues/60#issuecomment-462297845_ Hea oleks dokumentatsiooni täiendada, kui see nii ei ole. Mis on lives ja mis on viitega jne

janesmae commented 5 years ago

@janesmae - Kas nüüd on selle staatus muutunud? okestonia/opendata-issue-tracker#60 (comment)_ Hea oleks dokumentatsiooni täiendada, kui see nii ei ole. Mis on lives ja mis on viitega jne

Toodangu API asub api.riigikogu.ee vastavalt infole Avaandmete portaalis.

Käesolev repo sai ka uuenduse vastava infoga.

moll commented 5 years ago

Is it me or is the download link still broken?

https://api.riigikogu.ee/api/files/882e0370-4730-426f-bf6a-2b4033ece138/download still reports:

HTTP/1.1 403 Forbidden
Connection: keep-alive
Content-Length: 169
Content-Type: text/html
Date: Mon, 11 Feb 2019 12:58:37 GMT
Server: nginx/1.14.2
marmoluik commented 5 years ago

Downloading files via API is not implemented at the moment.

moll commented 5 years ago

Perhaps remove mentions of downloading from the documentation and any links to /download from responses until it's implemented.

Do you know when will it be implemented? From the closed issue and "won't fix" tag I'm guessing never? Why not? What use are references to files without an API to obtain them?

moll commented 5 years ago

^ Has this been reconsidered since February?