|
268 | 268 | }, |
269 | 269 | "default": { |
270 | 270 | "default": true, |
271 | | - "description": "This is the default routing table for this area. It can't be deleted and is used if the user does not specify it otherwise.", |
| 271 | + "description": "This is the default routing table. It can't be deleted and is used if the user does not specify it otherwise.", |
272 | 272 | "readOnly": true, |
273 | 273 | "type": "boolean" |
274 | 274 | }, |
|
430 | 430 | "CreateNetworkPayload": { |
431 | 431 | "description": "Object that represents the request body for a network create.", |
432 | 432 | "properties": { |
| 433 | + "dhcp": { |
| 434 | + "allOf": [ |
| 435 | + { |
| 436 | + "$ref": "#/components/schemas/DHCP" |
| 437 | + } |
| 438 | + ], |
| 439 | + "default": true |
| 440 | + }, |
433 | 441 | "ipv4": { |
434 | 442 | "$ref": "#/components/schemas/CreateNetworkIPv4" |
435 | 443 | }, |
|
460 | 468 | "format": "date-time", |
461 | 469 | "type": "string" |
462 | 470 | }, |
| 471 | + "DHCP": { |
| 472 | + "description": "Enable or disable DHCP for a network.", |
| 473 | + "example": true, |
| 474 | + "type": "boolean" |
| 475 | + }, |
463 | 476 | "Description": { |
464 | 477 | "description": "Description Object. Allows string up to 255 Characters.", |
465 | 478 | "example": "cool description dude. Wanna play some Snakeybus?", |
|
576 | 589 | "type": "array" |
577 | 590 | }, |
578 | 591 | "Network": { |
579 | | - "description": "Object that represents a network.", |
| 592 | + "description": "Object that represents a network. If no routing table is specified, the default routing table is used.", |
580 | 593 | "properties": { |
581 | 594 | "createdAt": { |
582 | 595 | "allOf": [ |
|
586 | 599 | ], |
587 | 600 | "readOnly": true |
588 | 601 | }, |
| 602 | + "dhcp": { |
| 603 | + "$ref": "#/components/schemas/DHCP" |
| 604 | + }, |
589 | 605 | "id": { |
590 | 606 | "$ref": "#/components/schemas/UUID" |
591 | 607 | }, |
|
628 | 644 | "type": "object" |
629 | 645 | }, |
630 | 646 | "NetworkGatewayIPv4": { |
631 | | - "allOf": [ |
632 | | - { |
633 | | - "$ref": "#/components/schemas/IPv4" |
634 | | - } |
635 | | - ], |
636 | 647 | "description": "The IPv4 gateway of a network. If not specified the first IP of the network will be assigned as the gateway. If 'null' is sent, then the network doesn't have a gateway.", |
637 | | - "nullable": true |
| 648 | + "example": "10.1.2.1", |
| 649 | + "nullable": true, |
| 650 | + "pattern": "^\\s*((([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5]))\\s*$", |
| 651 | + "type": "string" |
638 | 652 | }, |
639 | 653 | "NetworkGatewayIPv6": { |
640 | | - "allOf": [ |
641 | | - { |
642 | | - "$ref": "#/components/schemas/IPv6" |
643 | | - } |
644 | | - ], |
645 | 654 | "description": "The IPv6 gateway of a network. If not specified the first IP of the network will be assigned as the gateway. If 'null' is sent, then the network doesn't have a gateway.", |
646 | | - "nullable": true |
| 655 | + "example": "2001:db8:0:8d3:0:8a2e:70:1", |
| 656 | + "nullable": true, |
| 657 | + "pattern": "^\\s*((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*$", |
| 658 | + "type": "string" |
647 | 659 | }, |
648 | 660 | "NetworkIPv4": { |
649 | 661 | "description": "Object that represents the IPv4 part of a network.", |
|
789 | 801 | "PartialUpdateNetworkPayload": { |
790 | 802 | "description": "Object that represents the request body for a network update.", |
791 | 803 | "properties": { |
| 804 | + "dhcp": { |
| 805 | + "$ref": "#/components/schemas/DHCP" |
| 806 | + }, |
792 | 807 | "ipv4": { |
793 | 808 | "$ref": "#/components/schemas/UpdateNetworkIPv4Body" |
794 | 809 | }, |
|
949 | 964 | }, |
950 | 965 | "default": { |
951 | 966 | "default": true, |
952 | | - "description": "This is the default routing table for this area. It can't be deleted and is used if the user does not specify it otherwise.", |
| 967 | + "description": "This is the default routing table. It can't be deleted and is used if the user does not specify it otherwise.", |
953 | 968 | "readOnly": true, |
954 | 969 | "type": "boolean" |
955 | 970 | }, |
|
0 commit comments