ckanext-basket
This plugin allows users to create baskets. Users can create baskets to memorize and group datasets of special importance. Furthermore, user can download their basket data easily.




Basket symbol in the header:

API functions
You must be logged in in order to use any basket api function.
basket_create(context, data_dict)
Create a new basket. Normal users can only create baskets for themselves, thus Parameter “user_id” will be ignored.
Parameters:
* user_id (string) - The id of the user to create the basket for (only admin)
* name (string) - The name of the basket
* description (string) - Description of the basket
* element_type (string) - The type of the basket elements (e.g. package, resource, subset) (optional)
Returns:
the newly created basket.
Return type:
dictionary
basket_update(context, data_dict)
Update a basket. You can only update your own basket.
For further parameters see basket_create().
Parameters:
* id (string) - The id of the basket
Returns:
the updated basket.
Return type:
dictionary
basket_purge(context, data_dict)
Purge a basket. You can only purge your own basket.
Parameters:
* id (string) - The id of the basket
Returns:
/
basket_list(context, data_dict)
List all baskets for user. Only sysadmins can see other baskets, everyone else can only list his/her own baskets.
Parameters:
* user_id (string) - The id of the user for whom to list the baskets (only admin)
Returns:
a user’s baskets.
Return type
list of dicts
basket_show(context, data_dict)
Show basket with or without its elements. You are only allowed to do a basket_show of your own basket.
Parameters:
* id (string)