anchor.diff:              }
   
   
  -
  -## Retrieves al the created Hadoop clusters of a user [/stack]
  +## Retrieves al the created Hadoop  stacks [/stack]
   ### List stacks [GET]
  -Retrieve all Hadoop cluster configurations
  -
  -+ Request
  -
  -    + Headers
  -
  -            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  -            
  -    + Body
  -
  -            {
  -            
  -            }
  -
  -    + Response 200 (application/json)
  -    
  -            {
  -                TBD
  -            }
  -            
  -
  -        
  -##Describe one Hadoop cluster  [/stack/{id}]
  +Retrieve all Hadoop cluster stack
  +
  ++ Request
  +
  +    + Headers
  +
  +            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  +            
  +    + Body
  +
  +            {
  +            
  +            }
  +
  +    + Response 200 (application/json)
  +    
  +            {
  +                "stackName": "my-ambari-cluster-1",
  +                "blueprintBody": {
  +                "host_groups" : [
  +                      {
  +                        "name" : "master",
  +                        "components" : [
  +                            {
  +                              "name" : "NAMENODE"
  +                            },
  +                            {
  +                              "name" : "SECONDARY_NAMENODE"
  +                            },
  +                            {
  +                              "name" : "RESOURCEMANAGER"
  +                            },
  +                            {
  +                              "name" : "HISTORYSERVER"
  +                            },
  +                            {
  +                              "name" : "NAGIOS_SERVER"
  +                            },
  +                            {
  +                              "name" : "ZOOKEEPER_SERVER"
  +                            }
  +                        ],
  +                        "cardinality" : "1"
  +                      },
  +                      {
  +                        "name" : "slaves",
  +                        "components" : [
  +                            {
  +                              "name" : "DATANODE"
  +                            },
  +                            {
  +                              "name" : "HDFS_CLIENT"
  +                            },
  +                            {
  +                              "name" : "NODEMANAGER"
  +                            },
  +                            {
  +                              "name" : "YARN_CLIENT"
  +                            },
  +                            {
  +                              "name" : "MAPREDUCE2_CLIENT"
  +                            },
  +                            {
  +                              "name" : "ZOOKEEPER_CLIENT"
  +                            }
  +                            ],
  +                            "cardinality" : "2"
  +                      }
  +                    ],
  +                    "Blueprints" : {
  +                      "blueprint_name" : "multi-node-hdfs-yarn",
  +                      "stack_name" : "HDP",
  +                      "stack_version" : "2.0"
  +                    }
  +                  }
  +            
  +            }
  +            
  +
  +        
  +##Describe one Hadoop stack  [/stack/{id}]
  +### Retrieve one particulat Hadoop cluster stack [GET]
  +Retrieves one particulat Hadoop cluster stacj by submitting the stack id.
  ++ Parameters
  +    + id (required String `stack-id`) ... The identifier of the stack id.
  +
  ++ Request
  +
  +    + Headers
  +
  +            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  +
  ++ Response 200 (application/json)
  +
  +        {
  +                "stackName": "my-ambari-cluster-1",
  +                "blueprintBody": {
  +                "host_groups" : [
  +                      {
  +                        "name" : "master",
  +                        "components" : [
  +                            {
  +                              "name" : "NAMENODE"
  +                            },
  +                            {
  +                              "name" : "SECONDARY_NAMENODE"
  +                            },
  +                            {
  +                              "name" : "RESOURCEMANAGER"
  +                            },
  +                            {
  +                              "name" : "HISTORYSERVER"
  +                            },
  +                            {
  +                              "name" : "NAGIOS_SERVER"
  +                            },
  +                            {
  +                              "name" : "ZOOKEEPER_SERVER"
  +                            }
  +                        ],
  +                        "cardinality" : "1"
  +                      },
  +                      {
  +                        "name" : "slaves",
  +                        "components" : [
  +                            {
  +                              "name" : "DATANODE"
  +                            },
  +                            {
  +                              "name" : "HDFS_CLIENT"
  +                            },
  +                            {
  +                              "name" : "NODEMANAGER"
  +                            },
  +                            {
  +                              "name" : "YARN_CLIENT"
  +                            },
  +                            {
  +                              "name" : "MAPREDUCE2_CLIENT"
  +                            },
  +                            {
  +                              "name" : "ZOOKEEPER_CLIENT"
  +                            }
  +                            ],
  +                            "cardinality" : "2"
  +                      }
  +                    ],
  +                    "Blueprints" : {
  +                      "blueprint_name" : "multi-node-hdfs-yarn",
  +                      "stack_name" : "HDP",
  +                      "stack_version" : "2.0"
  +                    }
  +                  }
  +            }
  +
  +
  +##Deletes the specified stack from database [/stack/{id}]
  +### Deletes the stack[DELETE]
  +WARNING: Deletes the specified infrastructure from the cloud and all associated resources (VPC, subnet, internetGateway, routeTable, securityGroups, ACLs, instances)
  +
  ++ Parameters
  +    + id (required String `stacj-id`) ... The identifier of the stack.
  +
  ++ Request
  +
  +    + Headers
  +
  +            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  +
  ++ Response 200 (application/json)
  +
  +        {
  +            
  +        }
  +        
  +        
  +# Group Hadoop cluster  
  +Hadoop cluster related resources of the **Cloudbreak API**.
  +
  +Creates a Hadoop cluster from the given stack.
  +
  +## Creates a Hadoop stack [/cluster]
  +### Create infrastructure [POST]
  +Creates a Hadoop cluster based on the stack. The stack specifies the Hadoop services, the number of hosts in the hostgroup and other Hadoop specific configurations. 
  +Number of hosts in hostgroups can be overridean at cluster creation time.
  ++ Request
  +
  +    + Headers
  +
  +            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  +            
  +        
  +    + Body
  +
  +            {
  +                "clusterName": "my-hadoop-cluster-1",
  +                "stackId":"my-hadoop-stack-1"
  +                "host_groups" : [
  +                      {
  +                        "name" : "master",
  +                        "cardinality" : "1"
  +                      },
  +                      {
  +                        "name" : "slaves",
  +                        "cardinality" : "2"
  +                      }
  +                    ]
  +            }
  +
  +    + Response 200 (application/json)
  +    
  +            {
  +                
  +            }
  +
  +
  +
  +## Retrieves al the created Hadoop clusters from a stack [/cluster]
  +### List clusters [GET]
  +Retrieve all Hadoop clusters
  +
  ++ Request
  +
  +    + Headers
  +
  +            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  +            
  +    + Body
  +
  +            {
  +            
  +            }
  +
  +    + Response 200 (application/json)
  +    
  +            {
  +                "clusterName": "my-hadoop-cluster-1",
  +                "stackId":"my-hadoop-stack-1"
  +                "host_groups" : [
  +                      {
  +                        "name" : "master",
  +                        "cardinality" : "1"
  +                      },
  +                      {
  +                        "name" : "slaves",
  +                        "cardinality" : "2"
  +                      }
  +                    ]
  +            }
  +            
  +
  +        
  +##Describe one Hadoop cluster  [/cluster/{id}]
   ### Retrieve one particulat Hadoop cluster configuration [GET]
  -Retrieves thRetrieve one particulat Hadoop cluster configuration by submitting the stack ID
  +Retrieves one particulat Hadoop cluster configuration by submitting the cluster id
   + Parameters
  -    + id (required String `aws-infrastructure-id`) ... The identifier of the Azure `credential`.
  -
  -+ Request
  -
  -    + Headers
  -
  -            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  -
  -+ Response 200 (application/json)
  -
  -        {
  -            
  -            "id":"stack-123",
  -            "status":"CREATE_IN_PROGRESS",
  -            "creationTime":"2010-07-27T22:28:28Z",
  -            "ambariServerIP":"ambari.server.ip",
  -            "cloudPlatform": "AWS",
  -            "stackName": "my-stack-1",
  -            "nodeCount": 3,
  -            "description": "3 node AWS stack for Ambari provisioning",
  -            "credentialId":"credential-123",
  -            "parameters": {
  -              "region":"EU-WEST-1",
  -              "keyName":"sequence-eu",
  -              "addressPrefix": "172.16.0.0/16",
  -              "subnetAddressPrefix": "172.16.0.0/24",
  -              "instanceType": "M3.XLARGE",
  -              ... additional params if we want to further customize vpc, subnets, etc..
  -            }
  -                  
  -        }
  -
  -
  -##Deletes the specified infrastructure from the cloud [/infra/{id}]
  -### Deletes the infrastructure[DELETE]
  -WARNING: Deletes the specified infrastructure from the cloud and all associated resources (VPC, subnet, internetGateway, routeTable, securityGroups, ACLs, instances)
  +    + id (required String `cluster-id`) ... The identifier of the Hadoop cluster
  +
  ++ Request
  +
  +    + Headers
  +
  +            x-auth-token: user:c45sdfdsfo234jgkhsdgf324
  +
  ++ Response 200 (application/json)
  +
  +        {
  +                "clusterName": "my-hadoop-cluster-1",
  +                "stackId":"my-hadoop-stack-1"
  +                "host_groups" : [
  +                      {
  +                        "name" : "master",
  +                        "cardinality" : "1"
  +                      },
  +                      {
  +                        "name" : "slaves",
  +                        "cardinality" : "2"
  +                      }
  +                    ]
  +            }
  +
  +
  +##Deletes the specified Hadoop cluster [/cluster/{id}]
  +### Deletes the cluster[DELETE]
  +WARNING: Deletes the cluster - all data in HDFS will be lost. The cluster is destroyed.
   
   + Parameters
  -    + id (required String `aws-infrastructure-id`) ... The identifier of the Azure `credential`.
  +    + id (required String `cluster-id`) ... The identifier of the cluster.
   
   + Request
   
  
positive.code:             {
              
                  "id":"stack-123",
                  "status":"CREATE_IN_PROGRESS",
                  "creationTime":"2010-07-27T22:28:28Z",
                  "ambariServerIP":"ambari.server.ip",
                  "cloudPlatform": "AWS",
                  "stackName": "my-stack-1",
                  "nodeCount": 3,
                  "description": "3 node AWS stack for Ambari provisioning",
                  "credentialId":"credential-123",
                  "parameters": {
  
negative.code:             }
  
  ## Creates a Hadoop stack [/stack]
  ### Create stack [POST]
  Creates a Hadoop stack. The blueprint specifies the Hadoop services and other Hadoop specific configurations. 
  The blueprint is available behind a URL. The cardinality specifies the desired number of nodes for the hostgroup. When the cluster is created these number can be overrided.
  
  + Request
  
      + Headers
  