Hot answers tagged

7 votes
Accepted

How do I get a full list of datasets available on Data.Gov using the CKAN API?

For now the Data.gov CKAN API redirects package_list to package_search and for package_search the relevant Solr parameters to limit your query are rows and start. For example, http://catalog.data.gov/...
7 votes
Accepted

Is it possible to use CKAN for commercial use?

Yes. CKAN is licensed under Affero GNU GPL v3.0. From the preamble to the license: When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to ...
5 votes

Can I use another database instead of PostgreSQL in CKAN?

No, the only currently supported database backend is PostgreSQL. It was chosen as it is an open source, well supported and widely available solution. Support for other backends would need to be added ...
  • 568
5 votes
Accepted

How to download all datasets from a CKAN instance using the API?

This is not supported by the CKAN API, so you would need to script it.
4 votes

Extract all data from ckan

Did you have a look at CKAN's extensive API documentation? To get you started, look at the answer to related question How do I get a full list of datasets available on Data.Gov using the CKAN API? and ...
  • 2,794
4 votes
Accepted

Are the API keys on data.gov considered sensitive?

There are some API limits tied to a specific API key. If a third-party used your key, their calls would effect how many calls you can make.
  • 5,107
3 votes
Accepted

Alternation ("OR") searching

AFAIK, at least one : should be used in order to enable advanced search on CKAN: https://catalog.data.gov/dataset?q=title:abracadabra+OR+crime+OR+court+OR+justice+OR+pretrial
3 votes

Custom Categories in CKAN

The filters on the search page sidebar can be configured implementing the IFacets interface from your own extension (you'll need to write some code for that). For instance, these ones are defined ...
  • 568
3 votes

How to exclude datasets with no data on datahub.io search?

It's kind of hacky, but you can use a search engine like Google to search within a domain, and then exclude certain strings that indicate the dataset has no data. LINK In this case, the search ...
  • 17.3k
3 votes

Versions of CKAN datasets and its resources

Revisioning in CKAN is something that needs to be refactored and that is currently not exposed via the UI but internally objects are being revisioned and assigned a revision_id, including resources, ...
  • 568
2 votes

Official Help and Support on customising CKAN

Typically the best place for support with software is the software's website. Did you try visiting CKAN's site? At first glance, there's a link in the top navigation called "Support", so that's where ...
  • 11.8k
2 votes
Accepted

Is there a way to ask a CKAN repository only for changed datasets after a certain time?

Do not use the REST API, it's old and deprecated. Use the Action API. You can get the results you need using the package_search action, eg for datasets modified since 1st August 2026: http://demo....
  • 568
2 votes

CKAN - ckanext-scheming - Add dataset button

You can override the template snippets/add_dataset.html if you just want to have multiple add buttons. Here is what you can do (tested on CKAN 2.8.3): {# Adds 'Add Dataset' button #} {% set ...
2 votes
Accepted

Download CKAN Revisions

In this case, 2538d7f1-391b-4733-90b3-9e95cd5f3ea6 is a resource ID, not a revision ID. In CKAN, package(dataset) contains multiple resources and each of resources contain either actual data(file) or ...
2 votes

CKAN Harvester Issues

The harvester processes need to be running in order for the harvesting to work. As you mention you can fire up these manually for debugging and development, but in production you will want to use ...
  • 568
1 vote

How can we install CKAN on Windows using IDE?

Windows is not a supported platform for the service, according to the documentation. However, if you must have a Windows machine, you can follow the Docker compose installation guide that CKAN ...
1 vote
Accepted

CKAN Hierarchy extension breaks the home page

The problem is that the CKAN Hierarchy Extension does not work with CKAN 2.8 and higher. It has nothing to do with the installed Scheming Extension, nor the way it was configured. The issue is ...
  • 21
1 vote

Not able to view private datasets in CKAN using Nginx

Well done on this issue / question. It's more succinct than before and focuses more closely on 1 problem. I'll focus on your 3 issues together as they seem to be interrelated. You're right, I think ...
1 vote
Accepted

Solr not working while running CKAN over HTTPs using nginx and apache

You cannot reach solr from ckan because they are running in two different container on the same virtual network. If you run a container, a bridged network will be created by default. $ hostname -i ::...
1 vote

CKAN - Find and add tags to multiple datasets can this be done?

Yes, you can search all datasets that contain the word "agua" using the package_search API action, eg http://demo.ckan.org/api/3/action/package_search?q=agua Once you have them you can either: For ...
  • 568
1 vote

CKAN Harvester Issues

A second fix has been required to get default_groups working for Nick, thanks to his feedback and proposed PR as well. Note that that PR is still waiting review, so hopefully someone will confirm it ...
  • 2,321
1 vote

data.gov Action API Parameters Seem to be Ignored

So with a little fiddling, it looks like the field is actually working. The "count" remains unchanged, and I assume it refers to the total number of members in the dataset. However the actual number ...
  • 355
1 vote

Querying CKAN in Python using ckanapi

For some reason, the above solution has not worked for me. I tried data.gov catalog and used the same code as below: import ckanapi ckan = ckanapi.RemoteCKAN('https://catalog.data.gov') search_params ...
  • 11
1 vote

Querying CKAN in Python using ckanapi

Your issue is on line 2 of the "This doesn't work" snippet (the error is including the /api/3). It should be, as follows, in full: import ckanapi ckan = ckanapi.RemoteCKAN('https://data.noaa.gov') ...
1 vote

CKAN exposing tables from a relational database

Have you already tried the resources here? https://lists.okfn.org/mailman/listinfo/ckan-dev
  • 137
1 vote

Is there any way to get a package's resource's field names/datatypes with downloading the entire resource?

If the site in question has enabled it, the CKAN's Datastore allows you to query tabular data directly via additional API functions. In your case you would probably use the datastore_info function to ...
1 vote

Installing GeoJSON preview plugin on CKAN

Just to be clear, you still need to do the steps on the "Install the extension" section to enable the plugin. As an aside, we will move the geospatial previews to a separate CKAN extension to avoid ...
  • 568
1 vote

How do I get a full list of datasets available on Data.Gov using the CKAN API?

The API documentation lists two arguments to package_list : Parameters: limit (int) – if given, the list of datasets will be broken into pages of at most limit datasets per page and only one page ...
  • 4,485
1 vote

The Data.gov organization_list CKAN API is not working

Thanks to Philip Ashlock for providing the following answer: These are both known, but unfortunately unresolved issues. You can track their status on github at https://github.com/GSA/data.gov/...

Only top scored, non community-wiki answers of a minimum length are eligible