commit/galaxy-central: carlfeberhard: API Documentation: small fixes for histories, history_contents
1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/318f84a819ef/ Changeset: 318f84a819ef User: carlfeberhard Date: 2013-08-01 21:35:45 Summary: API Documentation: small fixes for histories, history_contents Affected #: 2 files diff -r 8be96f5579e7f228fac8e7b70ac4bbec261b445d -r 318f84a819ef9d71dbfffa700d93665b596ef440 lib/galaxy/webapps/galaxy/api/histories.py --- a/lib/galaxy/webapps/galaxy/api/histories.py +++ b/lib/galaxy/webapps/galaxy/api/histories.py @@ -28,9 +28,7 @@ return undeleted histories for the current user * GET /api/histories/deleted: return deleted histories for the current user - - If the user is logged-in, a full list of all histories is shown. - If not logged in, only the curernt history (if any) is shown. + .. note:: Anonymous users are allowed to get their current history :type deleted: boolean :param deleted: if True, show only deleted histories, if False, non-deleted @@ -76,6 +74,7 @@ return the deleted history with ``id`` * GET /api/histories/most_recently_used: return the most recently used history + .. note:: Anonymous users are allowed to get their current history :type id: an encoded id string :param id: the encoded id of the history to query or the string 'most_recently_used' @@ -127,8 +126,8 @@ create a new history :type payload: dict - :param payload: (optional) dictionary structure containing:: - 'name': the new history's name + :param payload: (optional) dictionary structure containing: + * name: the new history's name :rtype: dict :returns: element view of new history @@ -159,16 +158,16 @@ :type id: str :param id: the encoded id of the history to delete :type kwd: dict - :param kwd: (optional) dictionary structure containing:: - 'payload': a dictionary itself containing:: - 'purge': if True, purge the history and all of it's HDAs + :param kwd: (optional) dictionary structure containing: + + * payload: a dictionary itself containing: + * purge: if True, purge the history and all of it's HDAs :rtype: dict - :returns: an error object if an error occurred or a dictionary containing:: - - id: the encoded id of the history, - deleted: if the history was marked as deleted, - purged: if the history was purged + :returns: an error object if an error occurred or a dictionary containing: + * id: the encoded id of the history, + * deleted: if the history was marked as deleted, + * purged: if the history was purged """ history_id = id # a request body is optional here @@ -255,9 +254,9 @@ :param id: the encoded id of the history to undelete :type payload: dict :param payload: a dictionary containing any or all the - fields in :func:`galaxy.model.History.get_api_value` and/or the following:: + fields in :func:`galaxy.model.History.get_api_value` and/or the following: - 'annotation': an annotation for the history + * annotation: an annotation for the history :rtype: dict :returns: an error object if an error occurred or a dictionary containing @@ -330,4 +329,3 @@ pass #log.warn( 'unknown key: %s', str( key ) ) return validated_payload - diff -r 8be96f5579e7f228fac8e7b70ac4bbec261b445d -r 318f84a819ef9d71dbfffa700d93665b596ef440 lib/galaxy/webapps/galaxy/api/history_contents.py --- a/lib/galaxy/webapps/galaxy/api/history_contents.py +++ b/lib/galaxy/webapps/galaxy/api/history_contents.py @@ -18,28 +18,24 @@ index( self, trans, history_id, ids=None, **kwd ) * GET /api/histories/{history_id}/contents return a list of HDA data for the history with the given ``id`` + .. note:: Anonymous users are allowed to get their current history contents + + If Ids is not given, index returns a list of *summary* objects for + every HDA associated with the given `history_id`. + + If ids is given, index returns a *more complete* json object for each + HDA in the ids list. :type history_id: str :param history_id: encoded id string of the HDA's History :type ids: str :param ids: (optional) a comma separated list of encoded `HDA` ids - If Ids is not given, index returns a list of *summary* objects for - every HDA associated with the given `history_id`. - - .. seealso:: - :func:`_summary_hda_dict` - - If ids is given, index returns a *more complete* json object for each - HDA in the ids list. - - .. seealso:: - :func:`galaxy.web.base.controller.UsesHistoryDatasetAssociationMixin.get_hda_dict` - - .. note:: Anonymous users are allowed to get their current history contents - :rtype: list :returns: dictionaries containing summary or detailed HDA information + .. seealso:: + :func:`_summary_hda_dict` and + :func:`galaxy.web.base.controller.UsesHistoryDatasetAssociationMixin.get_hda_dict` """ rval = [] try: @@ -111,18 +107,16 @@ show( self, trans, id, history_id, **kwd ) * GET /api/histories/{history_id}/contents/{id} return detailed information about an HDA within a history + .. note:: Anonymous users are allowed to get their current history contents :type id: str :param ids: the encoded id of the HDA to return :type history_id: str :param history_id: encoded id string of the HDA's History - .. seealso:: :func:`galaxy.web.base.controller.UsesHistoryDatasetAssociationMixin.get_hda_dict` - - .. note:: Anonymous users are allowed to get their current history contents - :rtype: dict :returns: dictionary containing detailed HDA information + .. seealso:: :func:`galaxy.web.base.controller.UsesHistoryDatasetAssociationMixin.get_hda_dict` """ hda_dict = {} try: @@ -217,9 +211,9 @@ :type payload: dict :param payload: a dictionary containing any or all the fields in :func:`galaxy.model.HistoryDatasetAssociation.get_api_value` - and/or the following:: + and/or the following: - 'annotation': an annotation for the history + * annotation: an annotation for the HDA :rtype: dict :returns: an error object if an error occurred or a dictionary containing Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
participants (1)
-
commits-noreply@bitbucket.org