Full table of contents
- User guide
- Sysadmin guide
- Maintainer’s guide
- CKAN releases
- Installing CKAN
- Package install
- Source install
- Docker Compose install
- Installing CKAN from package
- Installing CKAN from source
- Deploying a source install
- Upgrading CKAN
- Getting started
- Database Management
- Command Line Interface (CLI)
- CLI command: ckan shell
- Troubleshooting ckan Commands
- ckan Commands Reference
- asset: WebAssets commands
- config: Search, validate, describe config options
- config-tool: Tool for editing options in a CKAN config file
- datapusher: Perform commands in the datapusher
- dataset: Manage datasets
- datastore: Perform commands in the datastore
- db: Manage databases
- generate: Scaffolding for regular development tasks
- jobs: Manage background jobs
- sass: Compile all root sass documents into their CSS counterparts
- notify: Send out modification notifications
- plugin-info: Provide info on installed plugins
- profile: Code speed profiler
- run: Start Development server
- search-index: Search index commands
- search-index: Rebuild search index
- sysadmin: Give sysadmin rights
- tracking: Update tracking statistics
- translation: Translation helper functions
- user: Create and manage users
- views: Create views on relevant resources
- Organizations and authorization
- Data preview and visualization
- FileStore and file uploads
- DataStore extension
- Relationship to FileStore
- Setting up the DataStore
- Automatically Adding Data to the DataStore
- Data Dictionary
- Downloading Resources
- The Data API
- Making a Data API request
- API reference
datastore_create()datastore_run_triggers()datastore_upsert()datastore_info()datastore_delete()datastore_records_delete()datastore_search()datastore_search_sql()set_datastore_active_flag()datastore_function_create()datastore_function_delete()- Fields
- Records
- Field types
- Filters
- Resource aliases
- Comparison of different querying methods
- Internal structure of the database
- Extending DataStore
get_all_resources_ids_in_datastore()DatastoreExceptionDatastoreBackendDatastoreBackend.register_backends()DatastoreBackend.set_active_backend()DatastoreBackend.get_active_backend()DatastoreBackend.configure()DatastoreBackend.create()DatastoreBackend.upsert()DatastoreBackend.delete()DatastoreBackend.search()DatastoreBackend.search_sql()DatastoreBackend.resource_exists()DatastoreBackend.resource_fields()DatastoreBackend.resource_info()DatastoreBackend.resource_id_from_alias()DatastoreBackend.get_all_ids()DatastoreBackend.create_function()DatastoreBackend.drop_function()
- Table Designer extension
- Table Designer vs. resource uploads and links
- Setting up Table Designer
- Creating a Table Designer resource
- Creating fields with the Data Dictionary
- Field Types
- Creating and updating rows with the web form
- Creating and updating rows with ckanext-excelforms
- Deleting rows
- Tracking changes with ckanext-dsaudit
- Apps & Ideas
- Tag Vocabularies
- Form Integration
- Linked Data and RDF
- Background jobs
- Email notifications
- Page View Tracking
- Multilingual Extension
- Stats Extension
- Configuration Options
- Environment variables
- Updating configuration options during runtime
- Config declaration
- CKAN configuration file
- Default settings
- General settings
- Development settings
- Session settings
- Database settings
- Site Settings
- Authorization Settings
- ckan.auth.anon_create_dataset
- ckan.auth.create_unowned_dataset
- ckan.auth.create_dataset_if_not_in_organization
- ckan.auth.user_create_groups
- ckan.auth.user_create_organizations
- ckan.auth.user_delete_groups
- ckan.auth.user_delete_organizations
- ckan.auth.create_user_via_api
- ckan.auth.create_user_via_web
- ckan.auth.roles_that_cascade_to_sub_groups
- ckan.auth.public_user_details
- ckan.auth.public_activity_stream_detail
- ckan.auth.allow_dataset_collaborators
- ckan.auth.allow_admin_collaborators
- ckan.auth.allow_collaborators_to_change_owner_org
- ckan.auth.create_default_api_keys
- ckan.auth.login_view
- ckan.auth.reveal_private_datasets
- ckan.auth.enable_cookie_auth_in_api
- ckan.auth.route_after_login
- CSRF Protection
- Flask-Login Remember me cookie settings
- API Token Settings
- Search Settings
- ckan.site_id
- solr_url
- solr_user
- solr_password
- ckan.search.remove_deleted_packages
- ckan.search.solr_commit
- ckan.search.solr_allowed_query_parsers
- ckan.search.show_all_types
- ckan.search.default_include_private
- ckan.search.default_package_sort
- search.facets.limit
- search.facets.default
- ckan.extra_resource_fields
- ckan.search.rows_max
- ckan.group_and_organization_list_max
- ckan.group_and_organization_list_all_fields_max
- solr_timeout
- Redis Settings
- CORS Settings
- Plugins Settings
- Front-End Settings
- ckan.site_title
- ckan.site_description
- ckan.site_intro_text
- ckan.site_logo
- ckan.site_about
- ckan.theme
- ckan.favicon
- ckan.datasets_per_page
- package_hide_extras
- ckan.recaptcha.publickey
- ckan.recaptcha.privatekey
- ckan.featured_groups
- ckan.featured_orgs
- ckan.default_group_sort
- ckan.gravatar_default
- ckan.debug_supress_header
- ckan.site_custom_css
- Resource Views Settings
- Theming Settings
- Storage Settings
- Uploader Settings
- Webassets Settings
- User Settings
- Activity Streams Settings
- Feeds Settings
- Internationalisation Settings
- Form Settings
- Email settings
- Background Job Settings
- Resource Proxy settings
- text_view settings
- image_view settings
- datatables_view settings
- Datastore settings
- ckan.datastore.write_url
- ckan.datastore.read_url
- ckan.datastore.sqlsearch.allowed_functions_file
- ckan.datastore.sqlsearch.enabled
- ckan.datastore.search.rows_default
- ckan.datastore.search.rows_max
- ckan.datastore.sqlalchemy.<OPTION>
- ckan.datastore.default_fts_lang
- ckan.datastore.default_fts_index_method
- ckan.datastore.default_fts_index_field_types
- Datapusher settings
- API guide
- Making an API request
- Example: Importing datasets with the CKAN API
- API versions
- Authentication and API tokens
- GET-able API functions
- JSONP support
- API Examples
- Action API reference
- ckan.logic.action.get
package_list()current_package_list_with_resources()member_list()package_collaborator_list()package_collaborator_list_for_user()group_list()organization_list()group_list_authz()organization_list_for_user()license_list()tag_list()user_list()package_relationships_list()package_show()resource_show()resource_view_show()resource_view_list()group_show()organization_show()group_package_show()tag_show()user_show()package_autocomplete()format_autocomplete()user_autocomplete()group_autocomplete()organization_autocomplete()package_search()resource_search()tag_search()tag_autocomplete()task_status_show()term_translation_show()get_site_user()status_show()vocabulary_list()vocabulary_show()user_follower_count()dataset_follower_count()group_follower_count()organization_follower_count()user_follower_list()dataset_follower_list()group_follower_list()organization_follower_list()am_following_user()am_following_dataset()am_following_group()followee_count()user_followee_count()dataset_followee_count()group_followee_count()organization_followee_count()followee_list()user_followee_list()dataset_followee_list()group_followee_list()organization_followee_list()member_roles_list()help_show()config_option_show()config_option_list()job_list()job_show()api_token_list()
- ckan.logic.action.create
package_create()resource_create()resource_view_create()resource_create_default_resource_views()package_create_default_resource_views()package_relationship_create()member_create()package_collaborator_create()group_create()organization_create()user_create()user_invite()vocabulary_create()tag_create()follow_user()follow_dataset()group_member_create()organization_member_create()follow_group()api_token_create()
- ckan.logic.action.update
resource_update()resource_view_update()resource_view_reorder()package_update()package_revise()package_resource_reorder()package_relationship_update()group_update()organization_update()user_update()task_status_update()task_status_update_many()term_translation_update()term_translation_update_many()vocabulary_update()package_owner_org_update()bulk_update_private()bulk_update_public()bulk_update_delete()config_option_update()
- ckan.logic.action.patch
- ckan.logic.action.delete
user_delete()package_delete()dataset_purge()resource_delete()resource_view_delete()resource_view_clear()package_relationship_delete()member_delete()package_collaborator_delete()group_delete()organization_delete()group_purge()organization_purge()task_status_delete()vocabulary_delete()tag_delete()unfollow_user()unfollow_dataset()group_member_delete()organization_member_delete()unfollow_group()job_clear()job_cancel()api_token_revoke()
- ckanext.activity.logic.action
send_email_notifications()dashboard_mark_activities_old()activity_create()user_activity_list()package_activity_list()group_activity_list()organization_activity_list()recently_changed_packages_activity_list()dashboard_activity_list()dashboard_new_activities_count()activity_show()activity_data_show()activity_diff()
- ckan.logic.action.get
- Extending guide
- Writing extensions tutorial
- Using custom config settings in extensions
- Making configuration options runtime-editable
- Testing extensions
- Best practices for writing extensions
- Follow CKAN’s coding standards
- Use the plugins toolkit instead of importing CKAN
- Don’t edit CKAN’s database tables
- Don’t automatically modify the database structure
- Use migrations when introducing new models
- Declare models using shared metadata
- Implement each plugin class in a separate Python module
- Avoid name clashes
- Internationalize user-visible strings
- Add third party libraries to requirements.txt
- Implementing CSRF protection
- Customizing dataset and resource metadata fields using IDatasetForm
- Plugin interfaces reference
SingletonPluginPluginimplements()InterfaceIMiddlewareIAuthFunctionsIDomainObjectModificationIFeedIGroupControllerIOrganizationControllerIPackageControllerIPackageController.read()IPackageController.create()IPackageController.edit()IPackageController.delete()IPackageController.after_dataset_create()IPackageController.after_dataset_update()IPackageController.after_dataset_delete()IPackageController.after_dataset_show()IPackageController.before_dataset_search()IPackageController.after_dataset_search()IPackageController.before_dataset_index()IPackageController.before_dataset_view()
IPluginObserverIConfigurableIConfigDeclarationIConfigurerIActionsIResourceUrlChangeIDatasetFormIDatasetForm.package_types()IDatasetForm.is_fallback()IDatasetForm.create_package_schema()IDatasetForm.update_package_schema()IDatasetForm.show_package_schema()IDatasetForm.setup_template_variables()IDatasetForm.new_template()IDatasetForm.read_template()IDatasetForm.edit_template()IDatasetForm.search_template()IDatasetForm.history_template()IDatasetForm.resource_template()IDatasetForm.package_form()IDatasetForm.resource_form()IDatasetForm.validate()IDatasetForm.prepare_dataset_blueprint()IDatasetForm.prepare_resource_blueprint()
IValidatorsIResourceViewIResourceControllerIResourceController.before_resource_create()IResourceController.after_resource_create()IResourceController.before_resource_update()IResourceController.after_resource_update()IResourceController.before_resource_delete()IResourceController.after_resource_delete()IResourceController.before_resource_show()
IGroupFormIGroupForm.is_organizationIGroupForm.is_fallback()IGroupForm.group_types()IGroupForm.group_controller()IGroupForm.create_group_schema()IGroupForm.update_group_schema()IGroupForm.show_group_schema()IGroupForm.new_template()IGroupForm.index_template()IGroupForm.read_template()IGroupForm.history_template()IGroupForm.edit_template()IGroupForm.group_form()IGroupForm.form_to_db_schema()IGroupForm.db_to_form_schema()IGroupForm.setup_template_variables()IGroupForm.validate()IGroupForm.prepare_group_blueprint()
ITagControllerITemplateHelpersIFacetsIAuthenticatorITranslationIUploaderIBlueprintIPermissionLabelsIForkObserverIApiTokenIClickISignal
- Plugins toolkit reference
ckan.plugins.toolkit.BaseModelckan.plugins.toolkit.CkanVersionExceptionckan.plugins.toolkit.DefaultDatasetFormckan.plugins.toolkit.DefaultGroupFormckan.plugins.toolkit.DefaultOrganizationFormckan.plugins.toolkit.HelperErrorckan.plugins.toolkit.Invalidckan.plugins.toolkit.NotAuthorizedckan.plugins.toolkit.ObjectNotFoundckan.plugins.toolkit.StopOnErrorckan.plugins.toolkit.UnknownValidatorckan.plugins.toolkit.ValidationErrorckan.plugins.toolkit._()ckan.plugins.toolkit.abort()ckan.plugins.toolkit.add_public_directory()ckan.plugins.toolkit.add_resource()ckan.plugins.toolkit.add_template_directory()ckan.plugins.toolkit.asbool()ckan.plugins.toolkit.asint()ckan.plugins.toolkit.aslist()ckan.plugins.toolkit.auth_allow_anonymous_access()ckan.plugins.toolkit.auth_disallow_anonymous_access()ckan.plugins.toolkit.auth_sysadmins_check()ckan.plugins.toolkit.baseckan.plugins.toolkit.blanketckan.plugins.toolkit.cckan.plugins.toolkit.chained_action()ckan.plugins.toolkit.chained_auth_function()ckan.plugins.toolkit.chained_helper()ckan.plugins.toolkit.check_access()ckan.plugins.toolkit.check_ckan_version()ckan.plugins.toolkit.ckanckan.plugins.toolkit.configckan.plugins.toolkit.current_userckan.plugins.toolkit.enqueue_job()ckan.plugins.toolkit.error_shout()ckan.plugins.toolkit.fresh_context()ckan.plugins.toolkit.gckan.plugins.toolkit.get_action()ckan.plugins.toolkit.get_converter()ckan.plugins.toolkit.get_endpoint()ckan.plugins.toolkit.get_or_bust()ckan.plugins.toolkit.get_validator()ckan.plugins.toolkit.hckan.plugins.toolkit.literalckan.plugins.toolkit.login_user()ckan.plugins.toolkit.logout_user()ckan.plugins.toolkit.mail_recipient()ckan.plugins.toolkit.mail_user()ckan.plugins.toolkit.missingckan.plugins.toolkit.navl_validate()ckan.plugins.toolkit.redirect_to()ckan.plugins.toolkit.render()ckan.plugins.toolkit.render_snippet()ckan.plugins.toolkit.requestckan.plugins.toolkit.requires_ckan_version()ckan.plugins.toolkit.side_effect_free()ckan.plugins.toolkit.signalsckan.plugins.toolkit.ungettext()ckan.plugins.toolkit.url_for()ckan.plugins.toolkit.validate_action_data()ckan.plugins.toolkit.validator_args()
- Validator functions reference
- Built-in validators
keep_extras()not_missing()not_empty()if_empty_same_as()both_not_empty()empty()ignore()default()configured_default()ignore_missing()ignore_empty()convert_int()unicode_only()unicode_safe()limit_to_configured_maximum()owner_org_validator()package_id_not_changed()int_validator()natural_number_validator()is_positive_integer()datetime_from_timestamp_validator()boolean_validator()isodate()package_id_exists()package_id_does_not_exist()resource_id_does_not_exist()group_id_does_not_exist()user_id_does_not_exist()resource_view_id_does_not_exist()package_name_exists()package_id_or_name_exists()resource_id_exists()uuid_validator()user_id_exists()user_id_or_name_exists()group_id_exists()group_id_or_name_exists()name_validator()package_name_validator()package_version_validator()duplicate_extras_key()group_name_validator()tag_length_validator()tag_name_validator()tag_not_uppercase()tag_string_convert()ignore_not_package_admin()ignore_not_sysadmin()ignore_not_group_admin()user_name_validator()user_both_passwords_entered()user_password_validator()user_passwords_match()user_password_not_empty()user_about_validator()vocabulary_name_validator()vocabulary_id_not_changed()vocabulary_id_exists()tag_in_vocabulary_validator()tag_not_in_vocabulary()url_validator()user_name_exists()role_exists()datasets_with_no_organization_cannot_be_private()list_of_strings()if_empty_guess_format()clean_format()no_loops_in_hierarchy()filter_fields_and_values_should_have_same_length()filter_fields_and_values_exist_and_are_valid()extra_key_not_in_root_schema()empty_if_not_sysadmin()strip_value()email_validator()collect_prefix_validate()dict_only()email_is_unique()one_of()json_object()extras_valid_json()convert_to_extras()convert_from_extras()extras_unicode_convert()free_tags_only()convert_to_tags()convert_from_tags()convert_user_name_or_id_to_id()convert_package_name_or_id_to_id()convert_group_name_or_id_to_id()convert_to_json_if_string()as_list()convert_to_list_if_string()json_or_string()json_list_or_string()remove_whitespace()
- Built-in validators
- Internationalizing strings in extensions
- Migration from Pylons to Flask
- Signals
- Customizing the DataStore Data Dictionary Form
- Customizing Table Designer Column Types and Constraints
- Custom Column Type Example
- Custom Column Constraint Example
- Interface Reference
- Column Type Reference
- ColumnType base class
- TextColumn
tdtype = "text" - ChoiceColumn
tdtype = "choice"ChoiceColumnChoiceColumn.labelChoiceColumn.descriptionChoiceColumn.exampleChoiceColumn.datastore_typeChoiceColumn.form_snippetChoiceColumn.design_snippetChoiceColumn.view_snippetChoiceColumn.choices()ChoiceColumn.sql_validate_rule()ChoiceColumn.excel_validate_rule()ChoiceColumn.datastore_field_schema()
- EmailColumn
tdtype = "email" - URIColumn
tdtype = "uri" - UUIDColumn
tdtype = "uuid" - NumericColumn
tdtype = "numeric" - IntegerColumn
tdtype = "integer" - BooleanColumn
tdtype = "boolean" - JSONColumn
tdtype = "json" - DateColumn
tdtype = "date" - TimestampColumn
tdtype = "timestamp"
- Column Constraint Reference
- String Escaping Functions
- Theming guide
- Customizing CKAN’s templates
- Creating a CKAN extension
- Replacing a default template file
- Jinja2
- Extending templates with
{% ckan_extends %} - Replacing template blocks with
{% block %} - Extending parent blocks with Jinja’s
{{ super() }} - Template helper functions
- Adding your own template helper functions
- Template snippets
- Adding your own template snippets
- HTML tags and CSS classes
- Accessing custom config settings from templates
- Adding static files
- Customizing CKAN’s CSS
- Adding CSS and JavaScript files using Webassets
- Customizing CKAN’s JavaScript
- Creating dynamic user interfaces with htmx
- Best practices for writing CKAN themes
- Custom Jinja2 tags reference
- Variables and functions available to templates
- Objects and methods available to JavaScript modules
- Template helper functions reference
HelperAttributeDictliteralcore_helper()chained_helper()redirect_to()get_site_protocol_and_host()url_for()url_for_static()url_for_static_or_external()is_url()url_is_local()full_current_url()current_url()lang()strxfrm()ckan_version()lang_native_name()is_rtl_language()get_rtl_theme()flash_notice()flash_error()flash_success()get_flashed_messages()link_to()nav_link()build_nav_main()build_nav_icon()build_nav()map_pylons_to_flask_route_name()default_group_type()default_package_type()humanize_entity_type()get_facet_items_dict()has_more_facets()get_param_int()sorted_extras()check_access()linked_user()group_name_to_title()truncate()markdown_extract()dict_list_reduce()gravatar()sanitize_url()user_image()pager_url()get_page_number()get_display_timezone()render_datetime()date_str_to_datetime()parse_rfc_2822_date()time_ago_from_timestamp()dataset_display_name()dataset_link()resource_display_name()resource_link()tag_link()group_link()organization_link()dump_json()snippet()convert_to_dict()follow_button()follow_count()add_url_param()remove_url_param()debug_inspect()groups_available()organizations_available()member_count()roles_translated()user_in_org_or_group()escape_js()get_pkg_dict_extra()get_request_param()html_auto_link()render_markdown()format_resource_items()get_allowed_view_types()rendered_resource_view()view_resource_url()resource_view_is_filterable()resource_view_get_fields()resource_view_is_iframed()resource_view_icon()resource_view_display_preview()resource_view_full_page()remove_linebreaks()list_dict_filter()SI_number_span()uploads_enabled()get_featured_organizations()get_featured_groups()featured_group_org()get_site_statistics()resource_formats_default_file()resource_formats()unified_resource_format()resource_url_type()check_config_permission()get_organization()license_options()get_translated()facets()mail_to()clean_html()load_plugin_helpers()sanitize_id()get_collaborators()can_update_owner_org()decode_view_request_filters()check_ckan_version()make_login_url()csrf_input()
- Template snippets reference
- JavaScript sandbox reference
- JavaScript API client reference
- CKAN jQuery plugins reference
- Customizing CKAN’s templates
- Contributing guide
- Reporting issues
- Translating CKAN
- Testing CKAN
- Writing commit messages
- Making a pull request
- Reviewing and merging a pull request
- Writing documentation
- Projects for beginner CKAN developers
- CKAN code architecture
- CSS coding standards
- HTML coding standards
- JavaScript coding standards
- Python coding standards
- String internationalization
- Unicode handling
- Testing coding standards
- Guidelines for writing tests
- How should tests be organized?
- Recipe for a test method
- How detailed should tests be?
- Creating test objects:
ckan.tests.factories - Test helper functions:
ckan.tests.helpers - Pytest fixtures
UserFactoryResourceFactoryResourceViewFactoryGroupFactoryPackageFactoryVocabularyFactoryTagFactorySystemInfoFactoryAPITokenFactorySysadminFactoryOrganizationFactoryckan_config()make_app()app()cli()reset_db()reset_index()reset_queues()reset_redis()clean_redis()clean_db()clean_queues()migrate_db_for()clean_index()with_plugins()test_request_context()with_request_context()mail_server()with_test_worker()with_extended_cli()reset_db_once()non_clean_db()FakeFileStoragecreate_with_upload()
- Mocking: the
mocklibrary - Writing
ckan.logic.actiontests - Writing
ckan.logic.authtests - Writing converter and validator tests
- No tests for
ckan.logic.schema.py - Writing
ckan.controllerstests - Writing
ckan.modeltests - Writing
ckan.libtests - Writing
ckan.pluginstests - Writing
ckan.ckanexttests
- Creating test objects:
- Guidelines for writing tests
- Frontend development guidelines
- Templating
- Assets
- Creating a new template
- Template Blocks
- Blocks in page.html
- Blocks in base.html
- Building a JavaScript Module
- Install frontend dependencies
- File structure
- Stylesheets
- JavaScript
- Database migrations
- Upgrading CKAN’s dependencies
- Doing a CKAN release
- Maintenance tools
- Changelog