github.com/thetreep/go-swagger@v0.0.0-20240223100711-35af64f14f01/fixtures/bugs/2919/edge-api/management/routers.yml (about) 1 --- 2 paths: 3 # 'transit-routers' is deprecated, remove after 19.x, use 'routers' instead 4 transit-routers: 5 get: 6 summary: List routers 7 description: | 8 Retrieves a list of router resources; supports filtering, sorting, and pagination. Requires admin access. 9 security: 10 - ztSession: [ ] 11 tags: 12 - Router 13 operationId: listTransitRouters 14 parameters: 15 - $ref: '../shared/parameters.yml#/limit' 16 - $ref: '../shared/parameters.yml#/offset' 17 - $ref: '../shared/parameters.yml#/filter' 18 responses: 19 '200': 20 $ref: '#/responses/listRouters' 21 '401': 22 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 23 '400': 24 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 25 post: 26 summary: Create a router resource 27 description: Create a router resource. Requires admin access. 28 security: 29 - ztSession: [ ] 30 tags: 31 - Router 32 operationId: createTransitRouter 33 parameters: 34 - name: router 35 in: body 36 required: true 37 description: A router to create 38 schema: 39 $ref: '#/definitions/routerCreate' 40 responses: 41 '201': 42 $ref: '../shared/standard-responses.yml#/responses/createResponse' 43 '400': 44 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 45 '401': 46 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 47 transit-routers-id: 48 parameters: 49 - $ref: '../shared/parameters.yml#/id' 50 get: 51 summary: Retrieves a single router 52 description: Retrieves a single router by id. Requires admin access. 53 security: 54 - ztSession: [ ] 55 tags: 56 - Router 57 operationId: detailTransitRouter 58 responses: 59 '200': 60 $ref: '#/responses/detailRouter' 61 '404': 62 $ref: '../shared/standard-responses.yml#/responses/notFoundResponse' 63 '401': 64 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 65 put: 66 summary: Update all fields on a router 67 description: Update all fields on a router by id. Requires admin access. 68 security: 69 - ztSession: [ ] 70 tags: 71 - Router 72 operationId: updateTransitRouter 73 parameters: 74 - name: router 75 in: body 76 required: true 77 description: A router update object 78 schema: 79 $ref: '#/definitions/routerUpdate' 80 responses: 81 '200': 82 $ref: '../shared/standard-responses.yml#/responses/updateResponse' 83 '400': 84 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 85 '404': 86 $ref: '../shared/standard-responses.yml#/responses/notFoundResponse' 87 '401': 88 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 89 patch: 90 summary: Update the supplied fields on a router 91 description: Update the supplied fields on a router. Requires admin access. 92 security: 93 - ztSession: [ ] 94 tags: 95 - Router 96 operationId: patchTransitRouter 97 parameters: 98 - name: router 99 in: body 100 required: true 101 description: A router patch object 102 schema: 103 $ref: '#/definitions/routerPatch' 104 responses: 105 '200': 106 $ref: '../shared/standard-responses.yml#/responses/patchResponse' 107 '400': 108 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 109 '404': 110 $ref: '../shared/standard-responses.yml#/responses/notFoundResponse' 111 '401': 112 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 113 delete: 114 summary: Delete a router 115 description: Delete a router by id. Requires admin access. 116 security: 117 - ztSession: [ ] 118 tags: 119 - Router 120 operationId: deleteTransitRouter 121 responses: 122 '200': 123 $ref: '../shared/standard-responses.yml#/responses/deleteResponse' 124 '400': 125 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 126 '401': 127 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 128 '409': 129 $ref: '../shared/standard-responses.yml#/responses/cannotDeleteReferencedResourceResponse' 130 routers: 131 get: 132 summary: List routers 133 description: | 134 Retrieves a list of router resources; supports filtering, sorting, and pagination. Requires admin access. 135 security: 136 - ztSession: [ ] 137 tags: 138 - Router 139 operationId: listRouters 140 parameters: 141 - $ref: '../shared/parameters.yml#/limit' 142 - $ref: '../shared/parameters.yml#/offset' 143 - $ref: '../shared/parameters.yml#/filter' 144 responses: 145 '200': 146 $ref: '#/responses/listRouters' 147 '401': 148 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 149 '400': 150 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 151 post: 152 summary: Create a router resource 153 description: Create a router resource. Requires admin access. 154 security: 155 - ztSession: [ ] 156 tags: 157 - Router 158 operationId: createRouter 159 parameters: 160 - name: router 161 in: body 162 required: true 163 description: A router to create 164 schema: 165 $ref: '#/definitions/routerCreate' 166 responses: 167 '201': 168 $ref: '../shared/standard-responses.yml#/responses/createResponse' 169 '400': 170 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 171 '401': 172 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 173 routers-id: 174 parameters: 175 - $ref: '../shared/parameters.yml#/id' 176 get: 177 summary: Retrieves a single router 178 description: Retrieves a single router by id. Requires admin access. 179 security: 180 - ztSession: [ ] 181 tags: 182 - Router 183 operationId: detailRouter 184 responses: 185 '200': 186 $ref: '#/responses/detailRouter' 187 '404': 188 $ref: '../shared/standard-responses.yml#/responses/notFoundResponse' 189 '401': 190 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 191 put: 192 summary: Update all fields on a router 193 description: Update all fields on a router by id. Requires admin access. 194 security: 195 - ztSession: [ ] 196 tags: 197 - Router 198 operationId: updateRouter 199 parameters: 200 - name: router 201 in: body 202 required: true 203 description: A router update object 204 schema: 205 $ref: '#/definitions/routerUpdate' 206 responses: 207 '200': 208 $ref: '../shared/standard-responses.yml#/responses/updateResponse' 209 '400': 210 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 211 '404': 212 $ref: '../shared/standard-responses.yml#/responses/notFoundResponse' 213 '401': 214 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 215 patch: 216 summary: Update the supplied fields on a router 217 description: Update the supplied fields on a router. Requires admin access. 218 security: 219 - ztSession: [ ] 220 tags: 221 - Router 222 operationId: patchRouter 223 parameters: 224 - name: router 225 in: body 226 required: true 227 description: A router patch object 228 schema: 229 $ref: '#/definitions/routerPatch' 230 responses: 231 '200': 232 $ref: '../shared/standard-responses.yml#/responses/patchResponse' 233 '400': 234 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 235 '404': 236 $ref: '../shared/standard-responses.yml#/responses/notFoundResponse' 237 '401': 238 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 239 delete: 240 summary: Delete a router 241 description: Delete a router by id. Requires admin access. 242 security: 243 - ztSession: [ ] 244 tags: 245 - Router 246 operationId: deleteRouter 247 responses: 248 '200': 249 $ref: '../shared/standard-responses.yml#/responses/deleteResponse' 250 '400': 251 $ref: '../shared/standard-responses.yml#/responses/badRequestResponse' 252 '401': 253 $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse' 254 '409': 255 $ref: '../shared/standard-responses.yml#/responses/cannotDeleteReferencedResourceResponse' 256 257 responses: 258 listRouters: 259 description: A list of specifications 260 schema: 261 $ref: '#/definitions/listRoutersEnvelope' 262 detailRouter: 263 description: A single router 264 schema: 265 $ref: '#/definitions/detailRouterEnvelope' 266 267 definitions: 268 listRoutersEnvelope: 269 type: object 270 required: 271 - meta 272 - data 273 properties: 274 meta: 275 $ref: '../shared/standard-responses.yml#/definitions/meta' 276 data: 277 $ref: '#/definitions/routerList' 278 detailRouterEnvelope: 279 type: object 280 required: 281 - meta 282 - data 283 properties: 284 meta: 285 $ref: '../shared/standard-responses.yml#/definitions/meta' 286 data: 287 $ref: '#/definitions/routerDetail' 288 routerList: 289 type: array 290 items: 291 $ref: '#/definitions/routerDetail' 292 routerDetail: 293 type: object 294 allOf: 295 - $ref: '../shared/base-entity.yml#/definitions/baseEntity' 296 - type: object 297 required: 298 - name 299 - isVerified 300 - isOnline 301 - fingerprint 302 - cost 303 - noTraversal 304 - disabled 305 properties: 306 name: 307 type: string 308 fingerprint: 309 type: string 310 isVerified: 311 type: boolean 312 isOnline: 313 type: boolean 314 enrollmentToken: 315 type: string 316 x-nullable: true 317 enrollmentJwt: 318 type: string 319 x-nullable: true 320 enrollmentCreatedAt: 321 type: string 322 format: date-time 323 x-nullable: true 324 enrollmentExpiresAt: 325 type: string 326 format: date-time 327 x-nullable: true 328 unverifiedFingerprint: 329 type: string 330 x-nullable: true 331 x-omitempty: false 332 unverifiedCertPem: 333 type: string 334 x-nullable: true 335 x-omitempty: false 336 cost: 337 type: integer 338 minimum: 0 339 maximum: 65535 340 noTraversal: 341 type: boolean 342 disabled: 343 type: boolean 344 routerCreate: 345 type: object 346 required: 347 - name 348 properties: 349 name: 350 type: string 351 cost: 352 type: integer 353 x-nullable: true 354 minimum: 0 355 maximum: 65535 356 noTraversal: 357 type: boolean 358 x-nullable: true 359 disabled: 360 type: boolean 361 x-nullable: true 362 tags: 363 $ref: '../shared/base-entity.yml#/definitions/tags' 364 routerUpdate: 365 type: object 366 required: 367 - name 368 properties: 369 name: 370 type: string 371 cost: 372 type: integer 373 x-nullable: true 374 minimum: 0 375 maximum: 65535 376 noTraversal: 377 type: boolean 378 x-nullable: true 379 disabled: 380 type: boolean 381 x-nullable: true 382 tags: 383 $ref: '../shared/base-entity.yml#/definitions/tags' 384 routerPatch: 385 type: object 386 properties: 387 name: 388 type: string 389 cost: 390 type: integer 391 x-nullable: true 392 minimum: 0 393 maximum: 65535 394 noTraversal: 395 type: boolean 396 x-nullable: true 397 disabled: 398 type: boolean 399 x-nullable: true 400 tags: 401 $ref: '../shared/base-entity.yml#/definitions/tags'