
PhpIPAM FirstFree
CertifiedGet the first free subnet within a master subnet
PhpIPAM FirstFree
Get the first free subnet within a master subnet
Returns the CIDR of the first available child-subnet slot within the given master subnet. Useful for automatically provisioning the next available prefix from a supernet. Raises an error if no free subnet slot exists.
type: io.kestra.plugin.phpipam.ipam.subnet.FirstFreeExamples
Get first free subnet
id: phpipam_subnet_first_free
namespace: company.team
tasks:
- id: first_free_subnet
type: io.kestra.plugin.phpipam.ipam.subnet.FirstFree
baseUrl: "https://ipam.example.com"
appId: myapp
auth:
appToken: "{{ secret('PHPIPAM_APP_TOKEN') }}"
subnetId: "5"
mask: "25"
Properties
appId *Requiredstring
Application ID
The API application identifier configured in phpIPAM under Administration → API.
It appears in the path segment /api/{appId}/.
auth *RequiredNon-dynamic
Authentication
Provide either appToken for static App-token authentication,
or username + password to obtain a per-run session token.
Supplying both, or neither, raises a validation error.
io.kestra.plugin.phpipam.PhpipamAuthentication
Static App token
A token generated in the phpIPAM administration panel under Administration → API.
Sent to phpIPAM via the token request header.
Mutually exclusive with username / password.
Password
Password for the phpIPAM user. Must be provided together with username.
Username
phpIPAM username used to obtain a per-session token via POST /api/{appId}/user/.
Must be provided together with password.
Mutually exclusive with appToken.
baseUrl *Requiredstring
Base URL of the phpIPAM instance
Root URL of the phpIPAM instance, e.g. https://ipam.example.com. No trailing slash needed.
mask *Requiredstring
Child subnet mask
CIDR prefix length (e.g. 25) of the free child subnet to find within the master subnet. phpIPAM requires this to locate the first free slot of the requested size.
subnetId *Requiredstring
Master subnet ID
Numeric ID of the master subnet from which the first free child subnet is requested.
insecureTls booleanstring
falseDisable TLS certificate validation
Set to true to trust all TLS certificates, including self-signed ones.
Intended for development or internal deployments only.
pluginDefaultsRef Non-dynamicstring
Reference (ref) of the pluginDefaults to apply to this task.
Outputs
cidr string
First free subnet CIDR
CIDR notation of the first available child subnet slot.