Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.6 / 3....
  • Linux Kernel 3.0.82 LTS...
  • KDE Software Compilatio...
  • PulseAudio 4.0
  • Wireshark 1.10.0
  • NetworkManager 0.9.8.2
  • LibreOffice 3.6.6 / 4.0...
  • SystemRescueCd 3.7.0
  • Linux Kernel 3.10 RC6
  • Ubuntu Tweak 0.8.5
  • Home > Linux > Programming > Libraries

    CKAN client 0.3

    Download button

    No screenshots available
    Downloads: 341  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    NOT RATED
    0 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    John Bywater | More programs
    MIT/X Consortium Lic... / FREE
    April 29th, 2010, 02:59 GMT
    ROOT / Programming / Libraries

     Read user reviews (0)  Refer to a friend  Subscribe

    CKAN client description

    The CKAN client Python package

    The CKAN client software may be used to make requests on the Comprehensive Knowledge Archive Network (CKAN) REST API.

    Synopsis:

    The simplest way to make CKAN requests is:

        import ckanclient

        # Instantiate the CKAN client.
        ckan = ckanclient.CkanClient(api_key=my_key)

        # Get the package list.
        package_list = ckan.package_register_get()
        print package_list

        # Get the tag list.
        tag_list = ckan.tag_register_get()
        print tag_list

        # Collect the package metadata.
        package_entity = {
            'name': my_package_name,
            'url': my_package_url,
            'download_url': my_package_download_url,
            'tags': my_package_keywords,
            'notes': my_package_long_description,
        }

        # Register the package.
        ckan.package_register_post(package_entity)

        # Get the details of a package.
        ckan.package_entity_get(package_name)
        package_entity = ckan.last_message
        print package_entity

        # Update the details of a package.
        ckan.package_entity_get(package_name)
        package_entity = ckan.last_message
        package_entity['url'] = new_package_url
        package_entity['notes'] = new_package_notes
        ckan.package_entity_put(package_entity)

        # List groups
        group_list = ckan.group_register_get()
        print group_list

        # Create a new group
        group_entity = {
            'name': my_group_name,
            'title': my_group_title,
            'description': my_group_description,
            'packages': group_package_names,
            }
        ckan.group_register_post(group_entity)

        # Get the details of a group.
        print ckan.group_entity_get(group_name)

        # Update the group details
        group_entity = ckan.last_message
        group_entity['title'] = new_group_title
        group_entity['packages'] = new_group_packages
        ckan.group_entity_put(group_entity)



    Product's homepage

    Requirements:

    · Python

      


    TAGS:

    CKAN requests | REST API | Comprehensive Knowledge Archive Network | CKAN | requests | client

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM