Apache CloudStack 4.19.0.0 Root Admin API Reference
					
                                        
                                        
                                    
                                createSecondaryStorageSelector
Creates a secondary storage selector, described by the heuristic rule.
Request parameters
| Parameter Name | Description | Required | 
| description | The description of the heuristic rule. | true | 
| heuristicrule | The heuristic rule, in JavaScript language. It is required that it returns the UUID of a secondary storage pool. An example of a rule is `if (snapshot.hypervisorType === 'KVM') { '7832f261-c602-4e8e-8580-2496ffbbc45d'; }` would allocate all snapshots with the KVM hypervisor to the specified secondary storage UUID. | true | 
| name | The name identifying the heuristic rule. | true | 
| type | The resource type directed to a specific secondary storage by the selector. Valid options are: ISO, SNAPSHOT, TEMPLATE and VOLUME. | true | 
| zoneid | The zone in which the heuristic rule will be applied. | true | 
Response Tags
| Response Name | Description | 
| id | ID of the heuristic. | 
| created | When the heuristic was created. | 
| description | Description of the heuristic. | 
| heuristicrule | The heuristic rule, in JavaScript language, used to select a secondary storage to be directed. | 
| name | Name of the heuristic. | 
| removed | When the heuristic was removed. | 
| type | The resource type directed to a specific secondary storage by the selector. Valid options are: ISO, SNAPSHOT, TEMPLATE and VOLUME. | 
| zoneid | The zone which the heuristic is valid upon. |