vlan : VLAN object.

Object Reference

References to vlan are object references.

The name part of the vlan object reference has the following components:

  • Name of VLAN View or/and VLAN Range to which this VLAN belongs.
  • Name of the VLAN.
  • Id of the VLAN.
Example:
vlan/ZG5zLnZsYW4kLmNvbS5pbmZvYmxveC5kbn:vl_view1/vlan1/1 vlan/ZG5zLnZsYW4kLmNvbS5pbmZvYmxveC5kbn:vl_view1/vl_range1/vlan1/1

Restrictions

The object does not support the following operations:

  • Scheduling
  • CSV export

The object cannot be managed on Cloud Platform members.

Fields

These fields are actual members of the object; thus, they can be requested by using _return_fields, if the fields are readable.

The basic version of the object contains the field(s): id, name, parent.

The following fields are required to create this object:

Field Notes
id  
name  
parent  

assigned_to

assigned_to

List of objects VLAN is assigned to.

Type

An array of the following objects: network, ipv6network.

This field supports nested return fields as described here.

Search

The field is available for search via

  • ‘:=’ (case insensitive search)
  • ‘=’ (exact equality)
  • ‘~=’ (regular expression)

Notes

The assigned_to cannot be updated.

assigned_to cannot be written.

comment

comment

A descriptive comment for this VLAN.

Type

String.

Values with leading or trailing white space are not valid for this field.

Create

The default value is empty.

Search

The field is available for search via

  • ‘:=’ (case insensitive search)
  • ‘=’ (exact equality)
  • ‘~=’ (regular expression)

contact

contact

Contact information for person/team managing or using VLAN.

Type

String.

Values with leading or trailing white space are not valid for this field.

Create

The default value is empty.

Search

The field is available for search via

  • ‘:=’ (case insensitive search)
  • ‘=’ (exact equality)
  • ‘~=’ (regular expression)

department

department

Department where VLAN is used.

Type

String.

Values with leading or trailing white space are not valid for this field.

Create

The default value is empty.

Search

The field is available for search via

  • ‘:=’ (case insensitive search)
  • ‘=’ (exact equality)
  • ‘~=’ (regular expression)

description

description

Description for the VLAN object, may be potentially used for longer VLAN names.

Type

String.

Values with leading or trailing white space are not valid for this field.

Create

The default value is empty.

Search

The field is available for search via

  • ‘:=’ (case insensitive search)
  • ‘=’ (exact equality)
  • ‘~=’ (regular expression)

extattrs

extattrs

Extensible attributes associated with the object.

For valid values for extensible attributes, see the following information.

Type

Extensible attributes.

This field allows +/- to be specified as part of the field name when updating the object, see the following information.

Create

The default value is empty.

Search

For how to search extensible attributes, see the following information.

id

id

VLAN ID value.

Type

Unsigned integer.

The field also supports automatic selection of the next available VLAN ID in the specified vlanview or vlanrange. You can specify the vlanview or vlanrange in the following way:

Using a vlanview or vlanrange WAPI reference:

  • func:nextavailablevlanid:<reference>

Scheduled and approval operations are not supported when using the automatic VLAN ID selection.

When you specify a vlanview/vlanrange for automatic VLAN ID selection, you should also add a parent field in the object to be inserted with the same vlanview/vlanrange because the vlanview/vlanrange for automatic VLAN ID selection is not used for the actual object insertion.

NOTE: Automatic selection is supported only for JSON and XML requests.

Examples:

  • func:nextavailablevlanid:vlanview/ZG5zLnZsYW5fdmlldyRW:vl_view1/1/100
  • func:nextavailablevlanid:vlanrange/ZG5zLm5ldHdvcmskMTAu:vl_view1/vl_range1/1/10

This field can also be retrieved from a function call as part of an object insertion. The supported function calls for this field are:

To find out if the function can be called when _object_parameters matches multiple objects, see the function documentation.

The default parameters are passed to the specified function call and can be overridden by passing different values for the same parameter in _parameters.

To execute the function call, a dictionary must be set in this field with the following parameters:

Mandatory Name Comment
Y _object_function The name of the function.
Y _result_field The field in which the function returns its result.
See comment _object The WAPI object type on which the function calls. Either _object or _object_ref must be set.
See comment _object_ref A WAPI object reference on which the function calls. Either _object or _object_ref must be set.
N _parameters The parameters to be passed to the function.
See comment _object_parameters The parameters used for the object search, mandatory if _object is set.

As part of the insertion, the object identified by _object and _object_parameters will be fetched, and the function identified by _object_function will be called with the parameters specified in _parameters. The result of this function will be retrieved and the field of this function specified in _result_field will be extracted and used as the value for this field.

Note that if the function call returns a list, and the field requires a single value, the first value on the list will be used.

The following example uses a value for the ‘next_available_ip’ field in the 9.0.0.0/8 network, excluding IP addresses 9.0.0.1 and 9.0.0.2:

{
    '_object_function': 'next_available_ip',
    '_parameters': {
        'exclude': ['9.0.0.1', '9.0.0.2'],
    },
    '_result_field': 'ips',
    '_object': 'network',
    '_object_parameters': {
        'network': '9.0.0.0/8',
        'network_view': 'newdefaultnv',
    }
}

Note this function call might not be valid for this particular field, this is just an example.

Create

The field is required on creation.

Search

The field is available for search via

  • ‘!=’ (negative search)
  • ‘=’ (exact equality)
  • ‘<=’ (less than search)
  • ‘>=’ (greater than search)

Notes

The id is part of the base object.

name

name

Name of the VLAN.

Type

String.

Values with leading or trailing white space are not valid for this field.

Create

The field is required on creation.

Search

The field is available for search via

  • ‘:=’ (case insensitive search)
  • ‘=’ (exact equality)
  • ‘~=’ (regular expression)

Notes

The name is part of the base object.

parent

parent

The VLAN View or VLAN Range to which this VLAN belongs.

Type

String.

This field supports nested return fields as described here.

Create

The field is required on creation.

Search

The field is available for search via

  • ‘=’ (exact equality)

Notes

The parent is part of the base object.

reserved

reserved

When set VLAN can only be assigned to IPAM object manually.

Type

Bool.

Create

The default value is False.

Search

The field is available for search via

  • ‘=’ (exact equality)

status

status

Status of VLAN object. Can be Assigned, Unassigned, Reserved.

Type

String.

Valid values are:
  • ASSIGNED
  • RESERVED
  • UNASSIGNED

Search

The field is available for search via

  • ‘=’ (exact equality)

Notes

The status cannot be updated.

status cannot be written.

Search-only Fields

These fields are used only for searching. They are not actual members of the object and therefore the server does not return these fields with this name unless they are nested return fields.

get_associations

get_associations

Option to return all associated VLANs from other VLAN Ranges.

Type

Bool.

Search

The field is available for search via

  • ‘=’ (exact equality)

Notes

get_associations is a search-only field.

Fields List

Field Type Req R/O Base Search
assigned_to obj N Y N : = ~
comment String N N N : = ~
contact String N N N : = ~
department String N N N : = ~
description String N N N : = ~
extattrs Extattr N N N ext
id Unsigned int Y N Y ! < = >
name String Y N Y : = ~
parent String Y N Y =
reserved Bool N N N =
status String N Y N =

Search-only Fields List

Field Type Search
get_associations Bool =