POST /api/subnets { "subnet": { "name": "QA2", "network_type": "IPv4", "network": "10.35.2.27", "mask": "255.255.255.0", "subnet_parameters_attributes": [ { "name": "mQlPmcGHjX,pievygiEM2,餷錔惌谡銍悻騚銀送跷,҆Ѐӄ҄эҬ҄ӳӯѰ,<hr>UrzMjyavWK</hr>,ãÍïûýÞÔÆîÊ,1244362608,𫎢住𩀡𤝀䓿𨉩谖𗩒軉賢,^[.:=!:#]}", "value": "bar" } ] } } 201 { "network": "10.35.2.27", "network_type": "IPv4", "cidr": 24, "mask": "255.255.255.0", "priority": null, "vlanid": null, "mtu": 1500, "gateway": null, "dns_primary": null, "dns_secondary": null, "from": null, "to": null, "created_at": "2018-11-15 19:01:32 UTC", "updated_at": "2018-11-15 19:01:32 UTC", "ipam": "None", "boot_mode": "DHCP", "id": 1018350796, "name": "QA2", "description": null, "network_address": "10.35.2.27/24", "dhcp_id": null, "dhcp_name": null, "tftp_id": null, "tftp_name": null, "httpboot_id": null, "httpboot_name": null, "dns_id": null, "template_id": null, "template_name": null, "dhcp": null, "tftp": null, "httpboot": null, "dns": null, "template": null, "domains": [], "interfaces": [], "parameters": [ { "priority": 40, "created_at": "2018-11-15 19:01:32 UTC", "updated_at": "2018-11-15 19:01:32 UTC", "id": 767575239, "name": "mQlPmcGHjX,pievygiEM2,餷錔惌谡銍悻騚銀送跷,҆Ѐӄ҄эҬ҄ӳӯѰ,<hr>UrzMjyavWK</hr>,ãÍïûýÞÔÆîÊ,1244362608,𫎢住𩀡𤝀䓿𨉩谖𗩒軉賢,^[.:=!:#]}", "value": "bar" } ], "locations": [], "organizations": [] }
Param name | Description |
---|---|
location_id optional |
Scope by locations Validations:
|
organization_id optional |
Scope by organizations Validations:
|
subnet required |
Validations:
|
subnet[name] required |
Subnet name Validations:
|
subnet[description] optional , nil allowed |
Subnet description Validations:
|
subnet[network_type] optional , nil allowed |
Type or protocol, IPv4 or IPv6, defaults to IPv4 Validations:
|
subnet[network] required |
Subnet network Validations:
|
subnet[mask] required |
Netmask for this subnet Validations:
|
subnet[gateway] optional , nil allowed |
Subnet gateway Validations:
|
subnet[dns_primary] optional , nil allowed |
Primary DNS for this subnet Validations:
|
subnet[dns_secondary] optional , nil allowed |
Secondary DNS for this subnet Validations:
|
subnet[ipam] optional , nil allowed |
IP Address auto suggestion mode for this subnet, valid values are “DHCP”, “Internal DB”, “None” Validations:
|
subnet[from] optional , nil allowed |
Starting IP Address for IP auto suggestion Validations:
|
subnet[to] optional , nil allowed |
Ending IP Address for IP auto suggestion Validations:
|
subnet[vlanid] optional , nil allowed |
VLAN ID for this subnet Validations:
|
subnet[mtu] optional , nil allowed |
MTU for this subnet Validations:
|
subnet[domain_ids] optional , nil allowed |
Domains in which this subnet is part Validations:
|
subnet[dhcp_id] optional , nil allowed |
DHCP Proxy ID to use within this subnet Validations:
|
subnet[tftp_id] optional , nil allowed |
TFTP Proxy ID to use within this subnet Validations:
|
subnet[httpboot_id] optional , nil allowed |
HTTPBoot Proxy ID to use within this subnet Validations:
|
subnet[dns_id] optional , nil allowed |
DNS Proxy ID to use within this subnet Validations:
|
subnet[template_id] optional , nil allowed |
Template HTTP(S) Proxy ID to use within this subnet Validations:
|
subnet[boot_mode] optional , nil allowed |
Default boot mode for interfaces assigned to this subnet, valid values are “Static”, “DHCP” Validations:
|
subnet[subnet_parameters_attributes] optional , nil allowed |
Array of parameters (name, value) Validations:
|
subnet[location_ids] optional , nil allowed |
REPLACE locations with given ids Validations:
|
subnet[organization_ids] optional , nil allowed |
REPLACE organizations with given ids. Validations:
|