.. Warning: this file is automatically generated. Edits will be lost .. list-table:: Functions defined in :mod:`CNRegister` :widths: 3 3 10 10 30 :header-rows: 1 * - Tier - Version - REST - Function - Parameters * - Tier 2 - 1.0, 2.0 - ``PUT /node/{nodeid}`` - :func:`updateNodeCapabilities` - (:class:`session`, :class:`nodeid`, :class:`node`) ``->`` boolean * - Tier 2 - 1.0, 2.0 - ``GET /node/{nodeid}`` - :func:`getNodeCapabilities` - (:class:`nodeid`) ``->`` :class:`Types.Node` * - Tier 2 - 1.0, 2.0 - ``POST /node`` - :func:`register` - (:class:`session`, :class:`node`) ``->`` :class:`Types.NodeReference` .. function:: updateNodeCapabilities(session,nodeid,node) -> boolean For updating the capabilities of the specified node. Most information is replaced by information in the new node, however, the node identifier, nodeType, ping, syncrhonization.lastHarvested, and synchronization.lastCompleteHarvest are preserved from the existing entry. Services in the old record not included in the new Node will be removed. Successful completion of this operation is indicated by a HTTP response status code of 200. Unsuccessful completion of this operation MUST be indicated by returning an appropriate exception. v2.0: The structure of :class:`v2_0.Types.Node` has changed. :Version: 1.0, 2.0 :REST URL: ``PUT /node/{nodeid}`` :param session: Session information that contains the identity of the calling user as retrieved from the X.509 certificate which must be traceable to the CILogon service. The subject of the session defaults to the :term:`public user` if the certificate was not provided with the request. Transmitted as part of the SSL handshake process. :type session: :class:`Types.Session` :param nodeid: The identifier of the existing node entry being updated. Transmitted as part of the URL path and must be escaped accordingly. :type nodeid: :class:`Types.NodeReference` :param node: An instance of :class`Types.Node` that contains the updated information. Transmitted as an UTF-8 encoded XML structure for the respective type as defined in the DataONE types schema, as a *File part* of the MIME multipart/mixed message. :type node: :class:`Types.Node` :returns: True if operation is successful :rtype: boolean :raises Exceptions.NotImplemented: ``(errorCode=501, detailCode=4820)`` The service is not implemented. :raises Exceptions.NotAuthorized: ``(errorCode=401, detailCode=4821)`` The :term:`Subject` does not have authority to modify the node registration information. :raises Exceptions.ServiceFailure: ``(errorCode=500, detailCode=4822)`` :raises Exceptions.InvalidRequest: ``(errorCode=400, detailCode=4823)`` The request was malformed. :raises Exceptions.NotFound: ``(errorCode=404, detailCode=4824)`` The requested nodeid is not available in the registry. :raises Exceptions.InvalidToken: ``(errorCode=401, detailCode=4825)`` .. function:: getNodeCapabilities(nodeid) -> Node For retrieving the capabilities of the specified node if it is registered on the Coordinating Node being called. v2.0: The structure of :class:`v2_0.Types.Node` has changed. :Version: 1.0, 2.0 :REST URL: ``GET /node/{nodeid}`` :param nodeid: The identifier of the existing node entry being looked up. Transmitted as part of the URL path and must be escaped accordingly. :type nodeid: :class:`Types.NodeReference` :returns: An instance of :class`Types.Node` that contains the Node information. :rtype: :class:`Types.Node` :raises Exceptions.NotImplemented: ``(errorCode=501, detailCode=4826)`` The service is not implemented. :raises Exceptions.ServiceFailure: ``(errorCode=500, detailCode=4827)`` :raises Exceptions.InvalidRequest: ``(errorCode=400, detailCode=4828)`` The request was malformed. :raises Exceptions.NotFound: ``(errorCode=404, detailCode=4829)`` The requested nodeid is not available in the registry. .. function:: register(session,node) -> NodeReference Register a new node in the system. If the node already exists, then a :exc:`IdentifierNotUnique` exception MUST be returned. v2.0: The structure of :class:`v2_0.Types.Node` has changed. :Version: 1.0, 2.0 :REST URL: ``POST /node`` :param session: Session information that contains the identity of the calling user as retrieved from the X.509 certificate which must be traceable to the CILogon service. The subject of the session defaults to the :term:`public user` if the certificate was not provided with the request. Transmitted as part of the SSL handshake process. :type session: :class:`Types.Session` :param node: An instance of :class:`Types.Node` that fully describes the node being registered. Note that some attributes will be set by the Coordinating Node. Transmitted as an UTF-8 encoded XML structure for the respective type as defined in the DataONE types schema, as a *File part* of the MIME multipart/mixed message. :type node: :class:`Types.Node` :returns: The identifier of the new node entry if successful, otherwise an error is raised. :rtype: :class:`Types.NodeReference` :raises Exceptions.NotImplemented: ``(errorCode=501, detailCode=4840)`` :raises Exceptions.NotAuthorized: ``(errorCode=401, detailCode=4841)`` :raises Exceptions.ServiceFailure: ``(errorCode=500, detailCode=4842)`` :raises Exceptions.InvalidRequest: ``(errorCode=400, detailCode=4843)`` :raises Exceptions.IdentifierNotUnique: ``(errorCode=409, detailCode=4844)`` :raises Exceptions.InvalidToken: ``(errorCode=401, detailCode=4845)``