geosolutions-it / ckanext-datitrentinoit

Ckan customizations for OpenData Trentino
1 stars 4 forks source link

ComunWeb: create client for ComunWeb API v2 #87

Open etj opened 2 years ago

etj commented 2 years ago

Create a class ComunWebClient that given the source URL, offers a generator over the resources. You may use as an example this client for geonode

As reported in the mai epic issue, you can use the URL https://www.comune.trento.it/api/opendata/v2/content/search?classes=opendata_dataset as a sample. It has about 276 datasets at the moment. It seems that the query returns all of the available datasets and can not be paginated.

The generator should loop over the items key, containing a list of dicts.