github.com/jbking/gohan@v0.0.0-20151217002006-b41ccf1c2a96/tests/test_schema.json (about) 1 { 2 "networks": [], 3 "policies": [ 4 { 5 "action": "*", 6 "effect": "allow", 7 "id": "admin_statement", 8 "principal": "admin", 9 "resource": { 10 "path": ".*" 11 } 12 }, 13 { 14 "action": "*", 15 "condition": [ 16 "is_owner" 17 ], 18 "effect": "allow", 19 "id": "member_statement", 20 "principal": "_member_", 21 "resource": { 22 "path": "/v2.0/network/[^/]+/?$", 23 "properties": [ 24 "id", 25 "description", 26 "name" 27 ] 28 } 29 }, 30 { 31 "action": "*", 32 "condition": [ 33 "is_owner" 34 ], 35 "effect": "allow", 36 "id": "member_statement2", 37 "principal": "_member_", 38 "resource": { 39 "path": "/v2.0/networks/?$", 40 "properties": [ 41 "id", 42 "description", 43 "name" 44 ] 45 } 46 } 47 ], 48 "schemas": [ 49 { 50 "id": "network", 51 "metadata": { 52 "state_versioning": true 53 }, 54 "plural": "networks", 55 "prefix": "/v2.0", 56 "schema": { 57 "properties": { 58 "description": { 59 "default": "", 60 "permission": [ 61 "create", 62 "update" 63 ], 64 "title": "Description", 65 "description": "Description", 66 "type": "string", 67 "unique": false 68 }, 69 "id": { 70 "format": "uuid", 71 "permission": [ 72 "create" 73 ], 74 "title": "ID", 75 "description": "ID", 76 "type": "string", 77 "unique": false 78 }, 79 "name": { 80 "permission": [ 81 "create", 82 "update" 83 ], 84 "title": "Name", 85 "description": "Name", 86 "type": "string", 87 "unique": false 88 }, 89 "providor_networks": { 90 "default": {}, 91 "permission": [ 92 "create", 93 "update" 94 ], 95 "properties": { 96 "segmentaion_type": { 97 "enum": [ 98 "vlan", 99 "vxlan", 100 "gre" 101 ], 102 "type": "string" 103 }, 104 "segmentation_id": { 105 "minimum": 0, 106 "type": "integer" 107 } 108 }, 109 "title": "Provider Networks", 110 "description": "Provider Networks", 111 "type": "object", 112 "unique": false 113 }, 114 "route_targets": { 115 "default": [], 116 "items": { 117 "type": "string" 118 }, 119 "permission": [ 120 "create", 121 "update" 122 ], 123 "title": "RouteTargets", 124 "description": "RouteTargets", 125 "type": "array", 126 "unique": false 127 }, 128 "tenant_id": { 129 "permission": [ 130 "create" 131 ], 132 "title": "Tenant", 133 "description": "Tenant", 134 "type": "string", 135 "unique": false 136 } 137 }, 138 "propertiesOrder": [ 139 "description", 140 "id", 141 "name", 142 "providor_networks", 143 "route_targets", 144 "tenant_id" 145 ], 146 "type": "object" 147 }, 148 "title": "Network", 149 "description": "network", 150 "singular": "network" 151 }, 152 { 153 "id": "subnet", 154 "metadata": { 155 "state_versioning": true 156 }, 157 "parent": "network", 158 "plural": "subnets", 159 "prefix": "/v2.0/network/:network", 160 "schema": { 161 "properties": { 162 "cidr": { 163 "permission": [ 164 "create" 165 ], 166 "title": "Cidr", 167 "description": "Cidr", 168 "type": "string", 169 "unique": false 170 }, 171 "description": { 172 "default": "", 173 "permission": [ 174 "create", 175 "update" 176 ], 177 "title": "Description", 178 "description": "Description", 179 "type": "string", 180 "unique": false 181 }, 182 "id": { 183 "format": "uuid", 184 "permission": [ 185 "create" 186 ], 187 "title": "ID", 188 "description": "ID", 189 "type": "string", 190 "unique": false 191 }, 192 "name": { 193 "permission": [ 194 "create", 195 "update" 196 ], 197 "title": "Name", 198 "description": "Name", 199 "type": "string", 200 "unique": false 201 }, 202 "tenant_id": { 203 "format": "uuid", 204 "permission": [ 205 "create" 206 ], 207 "title": "TenantID", 208 "description": "TenantID", 209 "type": "string", 210 "unique": false 211 } 212 }, 213 "propertiesOrder": [ 214 "cidr", 215 "description", 216 "id", 217 "name", 218 "tenant_id" 219 ], 220 "required": ["cidr"], 221 "type": "object" 222 }, 223 "title": "subnet", 224 "description": "subnet", 225 "singular": "subnet" 226 }, 227 { 228 "id": "net", 229 "plural": "nets", 230 "prefix": "/v2.0", 231 "schema": { 232 "required": [], 233 "properties": { 234 "cidr": { 235 "permission": [ 236 "create", 237 "update" 238 ], 239 "title": "CIDR", 240 "description": "CIDR", 241 "type": "string", 242 "unique": false, 243 "format": "cidr", 244 "default": "10.0.0.0/24" 245 }, 246 "mac": { 247 "permission": [ 248 "create", 249 "update" 250 ], 251 "title": "MAC", 252 "description": "MAC", 253 "type": "string", 254 "unique": false, 255 "format": "mac", 256 "default": "ab:ba:ab:ba:11:22" 257 }, 258 "id": { 259 "permission": [ 260 "create", 261 "update" 262 ], 263 "title": "UUID", 264 "description": "UUID", 265 "type": "string", 266 "unique": false, 267 "format": "uuid", 268 "default": "de305d54-75b4-431b-adb2-eb6b9e546014" 269 }, 270 "port": { 271 "permission": [ 272 "create", 273 "update" 274 ], 275 "title": "port", 276 "description": "port", 277 "type": "string", 278 "unique": false, 279 "format": "port", 280 "default": "42" 281 }, 282 "regex": { 283 "permission": [ 284 "create", 285 "update" 286 ], 287 "title": "regex", 288 "description": "regex", 289 "type": "string", 290 "unique": false, 291 "format": "regex", 292 "default": ".*" 293 } 294 }, 295 "propertiesOrder": [ 296 "cidr", 297 "mac", 298 "id", 299 "port", 300 "regex" 301 ], 302 "type": "object" 303 }, 304 "title": "net", 305 "description": "net", 306 "singular": "net" 307 } 308 ], 309 "subnets": [], 310 "nets": [] 311 }