Nodes API

class cloudify_rest_client.nodes.Node(node_instance)[source]

Bases: dict

Cloudify node.

id
Returns:The identifier of the node.
deployment_id
Returns:The deployment id the node belongs to.
properties
Returns:The static properties of the node.
operations
Returns:The node operations mapped to plugins.
Return type:dict
relationships
Returns:The node relationships with other nodes.
Return type:list
blueprint_id
Returns:The id of the blueprint this node belongs to.
Return type:str
plugins
Returns:The plugins this node has operations mapped to.
Return type:dict
number_of_instances
Returns:The number of instances this node has.
Return type:int
planned_number_of_instances
Returns:The planned number of instances this node has.
Return type:int
deploy_number_of_instances
Returns:The number of instances this set for this node when the deployment was created.
Return type:int
host_id
Returns:The id of the node instance which hosts this node.
Return type:str
type_hierarchy
Returns:The type hierarchy of this node.
Return type:list
type
Returns:The type of this node.
Return type:str
class cloudify_rest_client.nodes.NodesClient(api)[source]

Bases: object

list(deployment_id=None, node_id=None, _include=None, **kwargs)[source]

Returns a list of nodes which belong to the deployment identified by the provided deployment id.

Parameters:
  • deployment_id – The deployment’s id to list nodes for.
  • node_id – If provided, returns only the requested node. This parameter is deprecated, use ‘id’ instead.
  • _include – List of fields to include in response.
  • kwargs – Optional filter fields. for a list of available fields see the REST service’s models.DeploymentNode.fields
Returns:

Nodes.

Return type:

list

get(deployment_id, node_id, _include=None)[source]

Returns the node which belongs to the deployment identified by the provided deployment id .

Parameters:
  • deployment_id – The deployment’s id of the node.
  • node_id – The node id.
  • _include – List of fields to include in response.
Returns:

Nodes.

Return type:

Node