https://networkcalc.com/api/account/subnets/{subnet_id}
List one or more of the subnets saved to your account.
curl https://networkcalc.com/api/account/subnets/12345 \
--header "Authorization: Bearer 2jdS83kfDdDfllHk"
{
"status": "OK",
"subnets": [
{
"octet_1": 10,
"octet_2": 0,
"octet_3": 1,
"octet_4": 0,
"subnet_bits": 24,
"cidr_notation": "10.0.1.0/24",
"subnet_mask": {
"octet_1": "255",
"octet_2": "255",
"octet_3": "255",
"octet_4": "0"
},
"assignable_hosts": 254,
"id": 12345,
"is_active": 1,
"network_address": "10.0.1.0",
"name": "Example Subnet"
}
]
}
Parameters
{subnet_id}(Optional) The unique ID of the subnet.
Example: https://networkcalc.com/api/account/subnets/12345
Response Format
Response Codes
200
OK - Success.401
INVALID_REQUEST - The authorization header is missing.401
INVALID_GRANT - The given access token is expired or invalid.400
MISSING_HEADER - A required header is missing.400
MISSING_VALUES - One of the required parameters is missing from the body.400
NOT_UPDATED - The subnet could not be saved. Verify the request and try again.400
NOT_DELETED - The subnet could not be deleted. Verify the request and try again.400
NOT_FOUND - A subnet with the given ID could not be found.400
NETWORK_ADDRESS_INVALID - The supplied network address is incorrectly formatted or otherwise invalid.400
SYSTEM_ERROR - A system error occurred. Try the request again.