f5.bigip.tm.gtm

Module contents

BIG-IP® Global Traffic Manager™ (GTM®) module.

REST URI

http://localhost/mgmt/tm/gtm/

GUI Path

DNS

REST Kind

tm:gtm:*

Submodule List

datacenter

BIG-IP® Global Traffic Manager (GTM) datacenter module.

global_settings

BIG-IP® Global Traffic Manager™ (GTM®) global-settings submodule.

listener

BIG-IP® Global Traffic Manager™ (GTM®) Topology Records module.

monitor

BIG-IP® GTM monitor submodule.

pool

BIG-IP® Global Traffic Manager™ (GTM®) pool module.

region

BIG-IP® Global Traffic Manager™ (GTM®) Region module.

rule

BIG-IP® Global Traffic Manager (GTM) rule module.

server

BIG-IP® Global Traffic Manager™ (GTM®) pool module.

topology

BIG-IP® Global Traffic Manager™ (GTM®) Topology Records module.

wideip

BIG-IP® Global Traffic Manager™ (GTM®) pool module.

class f5.bigip.tm.gtm.Gtm(tm)[source]

BIG-IP® Global Traffic Manager (GTM) organizing collection.

Submodules

datacenter

BIG-IP® Global Traffic Manager (GTM) datacenter module.

REST URI

http://localhost/mgmt/tm/gtm/datacenter

GUI Path

DNS --> GSLB : Data Centers

REST Kind

tm:gtm:datacenter:*

class f5.bigip.tm.gtm.datacenter.Datacenters(gtm)[source]

BIG-IP® GTM datacenter collection

class f5.bigip.tm.gtm.datacenter.Datacenter(dc_s)[source]

BIG-IP® GTM datacenter resource

create(**kwargs)[source]

Create the resource on the BIG-IP®.

Uses HTTP POST to the collection URI to create a resource associated with a new unique URI on the device.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

All the key-values needed to create the resource.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.post method where it will be handled according to that API.

Returns:
Resource: A python object that represents the object’s configuration

and state on the BIG-IP®.

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

update(**kwargs)[source]

Update the configuration of the resource on the BIG-IP®.

This method uses HTTP PUT alter the resource state on the BIG-IP®.

The attributes of the instance will be packaged as a dictionary. That dictionary will be updated with kwargs. It is then submitted as JSON to the device.

Various edge cases are handled: * read-only attributes that are unchangeable are removed

Args:
kwargs (dict): Arbitrary number of keyword arguments.

Keys and associated values to alter on the device.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.put method where it will be handled according to that API.

global_settings

BIG-IP® Global Traffic Manager™ (GTM®) global-settings submodule.

REST URI

http://localhost/mgmt/tm/gtm/global-settings

GUI Path

DNS --> Settings --> GSLB

REST Kind

tm:gtm:global-settings*

class f5.bigip.tm.gtm.global_settings.Global_Settings(gtm)[source]

BIG-IP® GTM global-settings organizing collection.

class f5.bigip.tm.gtm.global_settings.General(global_settings)[source]

BIG-IP® GTM global-settings general resource.

class f5.bigip.tm.gtm.global_settings.Load_Balancing(global_settings)[source]

BIG-IP® GTM global-settings load balancing resource.

class f5.bigip.tm.gtm.global_settings.Metrics(global_settings)[source]

BIG-IP® GTM global-settings metrics resource.

listener

BIG-IP® Global Traffic Manager™ (GTM®) Topology Records module.

REST URI

http://localhost/mgmt/tm/gtm/listener

GUI Path

DNS --> Delivery : Topology : Records

REST Kind

tm:gtm:listener:*

class f5.bigip.tm.gtm.listener.Listeners(gtm)[source]

BIG-IP® GTM Listener collection

class f5.bigip.tm.gtm.listener.Listener(listeners)[source]

BIG-IP® GTM Listener resource

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

class f5.bigip.tm.gtm.listener.Profiles_s(server)[source]

BIG-IP® GTM Listener Profile sub-collection

class f5.bigip.tm.gtm.listener.Profile(profiles)[source]

BIG-IP® GTM Listener Profile sub-collection

Since GTM listener is a wrapper for LTM virtual, profile removal and profile attachment should be done via the created LTM virtual. Only loading or refresh of profiles is supported. Remainder of operations(Create, Update, Modify, Delete) should be done via LTM Virtual Server Profiles endpoint.

create(**kwargs)[source]

Create is not supported for profile sub-collection

Raises:

UnsupportedOperation

modify(**kwargs)[source]

Modify is not supported for profile sub-collection

Raises:

UnsupportedOperation

update(**kwargs)[source]

Update is not supported for profile sub-collection

Raises:

UnsupportedOperation

delete(**kwargs)[source]

Delete is not supported for profile sub-collection

Raises:

UnsupportedOperation

monitor

BIG-IP® GTM monitor submodule.

REST URI

http://localhost/mgmt/tm/gtm/monitor/

GUI Path

DNS --> GSLB --> Monitors

REST Kind

tm:gtm:monitor*

class f5.bigip.tm.gtm.monitor.Monitor(gtm)[source]
class f5.bigip.tm.gtm.monitor.Bigips(monitor)[source]
class f5.bigip.tm.gtm.monitor.Bigip(bigips)[source]
class f5.bigip.tm.gtm.monitor.Externals(monitor)[source]
class f5.bigip.tm.gtm.monitor.External(externals)[source]
class f5.bigip.tm.gtm.monitor.Firepass_s(monitor)[source]
class f5.bigip.tm.gtm.monitor.Firepass(firepass_s)[source]
class f5.bigip.tm.gtm.monitor.Ftps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Ftp(ftps)[source]
class f5.bigip.tm.gtm.monitor.Gateway_Icmps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Gateway_Icmp(gateway_icmps)[source]
class f5.bigip.tm.gtm.monitor.Gtps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Gtp(gtps)[source]
class f5.bigip.tm.gtm.monitor.Https(monitor)[source]
class f5.bigip.tm.gtm.monitor.Http(https)[source]
class f5.bigip.tm.gtm.monitor.Https_s(monitor)[source]

BIG-IP® Https monitor collection.

class f5.bigip.tm.gtm.monitor.HttpS(https_s)[source]

BIG-IP® Https monitor resource.

class f5.bigip.tm.gtm.monitor.Imaps(monitor)[source]

BIG-IP® Imap monitor collection.

class f5.bigip.tm.gtm.monitor.Imap(imaps)[source]

BIG-IP® Imap monitor resource.

class f5.bigip.tm.gtm.monitor.Ldaps(monitor)[source]

BIG-IP® Ldap monitor collection.

class f5.bigip.tm.gtm.monitor.Ldap(ldaps)[source]

BIG-IP® Ldap monitor resource.

class f5.bigip.tm.gtm.monitor.Mssqls(monitor)[source]

BIG-IP® Mssql monitor collection.

class f5.bigip.tm.gtm.monitor.Mssql(mssqls)[source]

BIG-IP® Mssql monitor resource.

class f5.bigip.tm.gtm.monitor.Mysqls(monitor)[source]

BIG-IP® MySQL monitor collection.

class f5.bigip.tm.gtm.monitor.Mysql(mysqls)[source]

BIG-IP® MySQL monitor resource.

class f5.bigip.tm.gtm.monitor.Nntps(monitor)[source]

BIG-IP® Nntps monitor collection.

class f5.bigip.tm.gtm.monitor.Nntp(nntps)[source]

BIG-IP® Nntps monitor resource.

class f5.bigip.tm.gtm.monitor.Nones(monitor)[source]

BIG-IP® None monitor collection.

class f5.bigip.tm.gtm.monitor.NONE(nones)[source]

BIG-IP® None monitor resource.

class f5.bigip.tm.gtm.monitor.Oracles(monitor)[source]

BIG-IP® Oracle monitor collection.

class f5.bigip.tm.gtm.monitor.Oracle(oracles)[source]

BIG-IP® Oracle monitor resource.

class f5.bigip.tm.gtm.monitor.Pop3s(monitor)[source]

BIG-IP® Pop3 monitor collection.

class f5.bigip.tm.gtm.monitor.Pop3(pop3s)[source]

BIG-IP® Pop3 monitor resource.

class f5.bigip.tm.gtm.monitor.Postgresqls(monitor)[source]

BIG-IP® PostGRES SQL monitor collection.

class f5.bigip.tm.gtm.monitor.Postgresql(postgresqls)[source]

BIG-IP® PostGRES SQL monitor resource.

class f5.bigip.tm.gtm.monitor.Radius_s(monitor)[source]

BIG-IP® radius monitor collection.

class f5.bigip.tm.gtm.monitor.Radius(radius_s)[source]

BIG-IP® radius monitor resource.

class f5.bigip.tm.gtm.monitor.Radius_Accountings(monitor)[source]

BIG-IP® radius accounting monitor collection.

class f5.bigip.tm.gtm.monitor.Radius_Accounting(radius_accountings)[source]

BIG-IP® radius accounting monitor resource.

class f5.bigip.tm.gtm.monitor.Real_Servers(monitor)[source]

BIG-IP® real-server monitor collection.

class f5.bigip.tm.gtm.monitor.Real_Server(real_servers)[source]

BIG-IP® real-server monitor resource.

update(**kwargs)[source]

Change the configuration of the resource on the device.

This method uses Http PUT alter the service state on the device.

The attributes of the instance will be packaged as a dictionary. That dictionary will be updated with kwargs. It is then submitted as JSON to the device. Various edge cases are handled:

  • read-only attributes that are unchangeable are removed

  • tmCommand attribute removed prior to PUT

  • agent attribute removed prior to PUT

  • post attribute removed prior to PUT

Parameters:

kwargs – keys and associated values to alter on the device

class f5.bigip.tm.gtm.monitor.Scripteds(monitor)[source]

BIG-IP® scripted monitor collection.

class f5.bigip.tm.gtm.monitor.Scripted(scripteds)[source]

BIG-IP® scripted monitor resource.

class f5.bigip.tm.gtm.monitor.Sips(monitor)[source]

BIG-IP® Sip monitor collection.

class f5.bigip.tm.gtm.monitor.Sip(sips)[source]

BIG-IP® Sip monitor resource.

class f5.bigip.tm.gtm.monitor.Smtps(monitor)[source]

BIG-IP® Smtp monitor collection.

class f5.bigip.tm.gtm.monitor.Smtp(smtps)[source]

BIG-IP® Smtp monitor resource.

class f5.bigip.tm.gtm.monitor.Snmps(monitor)[source]

BIG-IP® Smtp monitor collection.

class f5.bigip.tm.gtm.monitor.Snmp(snmps)[source]

BIG-IP® Smtp monitor resource.

class f5.bigip.tm.gtm.monitor.Soaps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Soap(soaps)[source]
class f5.bigip.tm.gtm.monitor.Tcps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Tcp(tcps)[source]
class f5.bigip.tm.gtm.monitor.Tcp_Half_Opens(monitor)[source]
class f5.bigip.tm.gtm.monitor.Tcp_Half_Open(tcp_half_opens)[source]
class f5.bigip.tm.gtm.monitor.Udps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Udp(udps)[source]
class f5.bigip.tm.gtm.monitor.Waps(monitor)[source]
class f5.bigip.tm.gtm.monitor.Wap(waps)[source]
class f5.bigip.tm.gtm.monitor.Wmis(monitor)[source]
class f5.bigip.tm.gtm.monitor.Wmi(wmis)[source]
update(**kwargs)[source]

Change the configuration of the resource on the device.

This method uses Http PUT alter the service state on the device.

The attributes of the instance will be packaged as a dictionary. That dictionary will be updated with kwargs. It is then submitted as JSON to the device. Various edge cases are handled:

  • read-only attributes that are unchangeable are removed

  • agent attribute removed prior to PUT

  • post attribute removed prior to PUT

  • method attribute removed prior to PUT

Parameters:

kwargs – keys and associated values to alter on the device

pool

BIG-IP® Global Traffic Manager™ (GTM®) pool module.

REST URI

http://localhost/mgmt/tm/gtm/pool

GUI Path

DNS --> GSLB : Pools

REST Kind

tm:gtm:pools:*

class f5.bigip.tm.gtm.pool.Pools(container)[source]

BIG-IP® GTM Pool factory

The GTM Pool factory object is used to provide a consistent user experience across the SDK, while supporting the breaking changes in the BIG-IP APIs.

Between the 11.x and 12.x releases of BIG-IP, the REST endpoint for Pool changed from a Collection to an OrganizingCollection. The result is that breaking changes occurred in the API.

This breakage led to a discussion on naming conventions because there appeared to be a conflict now. For example, depending on your version, only one of the following would work.

For 11.x,

tm.gtm.pools.pool.load(name=’foo’)

For 12.x,

tm.gtm.pools.a_s.a.load(name=’foo’)

but not both. To stick with a consistent user experience, we decided to override the __new__ method to support both examples above. The SDK automatically detects which one to use based on the BIG-IP you are communicating with.

class f5.bigip.tm.gtm.pool.Members_s(container)[source]

BIG-IP® GTM Members_s factory

The GTM Members_s factory is used here for code readability and maintenance purposes, to allow us to stay in conventions already set in this SDK, and at the same time accommodate changes between v11 and v12 versions of Members_s sub-collection

class f5.bigip.tm.gtm.pool.MembersCollection_v11(pool)[source]

v11.x BIG-IP® GTM pool members sub-collection

class f5.bigip.tm.gtm.pool.MembersCollectionA(pool)[source]

v12.x BIG-IP® GTM A pool members sub-collection

class f5.bigip.tm.gtm.pool.MembersCollectionAAAA(pool)[source]

v12.x BIG-IP® GTM AAAA pool members sub-collection

class f5.bigip.tm.gtm.pool.MembersCollectionCname(pool)[source]

v12.x BIG-IP® GTM CNAME pool members sub-collection

class f5.bigip.tm.gtm.pool.MembersCollectionMx(pool)[source]

v12.x BIG-IP® GTM MX pool members sub-collection

class f5.bigip.tm.gtm.pool.MembersCollectionNaptr(pool)[source]

v12.x BIG-IP® GTM NAPTR pool members sub-collection

class f5.bigip.tm.gtm.pool.MembersCollectionSrv(pool)[source]

v12.x BIG-IP® GTM SRV pool members sub-collection

class f5.bigip.tm.gtm.pool.Member(container)[source]

BIG-IP® GTM Members factory

The GTM Members factory is used here for code readability and maintenance purposes, to allow us to stay in conventions already set in this SDK, and at the same time accommodate changes between v11 and v12 versions of Members resource

class f5.bigip.tm.gtm.pool.MembersResource_v11(members_s)[source]

v11.x BIG-IP® GTM members resource

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.MembersResourceA(members_s)[source]

v12.x BIG-IP® GTM A pool members resource

create(**kwargs)[source]

This method needs to be created due to a bug in 12.x

The issue arises when you attempt to create a members sub-collection resource and while the operation succeeds BIGIP responds with 404.

By requiring partition as argument we have shielded ourselves from this issue in 12.0.0, however in v12.1.x the problem occurs, even when the partition parameter is submitted. Custom create method is required to catch and deal with iControlUnexpectedHTTPError exception.

Issue is tracked under: ID610441.

note:: If version is 12.x then we use this method, otherwise we use

_create method from Resource class as usual.

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.MembersResourceAAAA(members_s)[source]

v12.x BIG-IP® GTM AAAA pool members resource

create(**kwargs)[source]

This method needs to be created due to a bug in 12.x

The issue arises when you attempt to create a members sub-collection resource and while the operation succeeds BIGIP responds with 404.

By requiring partition as argument we have shielded ourselves from this issue in 12.0.0, however in v12.1.x the problem occurs, even when the partition parameter is submitted. Custom create method is required to catch and deal with iControlUnexpectedHTTPError exception.

Issue is tracked under: ID610441.

note:: If version is 12.x then we use this method, otherwise we use

_create method from Resource class as usual.

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.MembersResourceCname(members_s)[source]

v12.x BIG-IP® GTM CNAME pool members resource

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.MembersResourceMx(members_s)[source]

v12.x BIG-IP® GTM MX pool members resource

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.MembersResourceNaptr(members_s)[source]

v12.x BIG-IP® GTM NAPTR pool members resource

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.MembersResourceSrv(members_s)[source]

v12.x BIG-IP® GTM SRV pool members resource

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

class f5.bigip.tm.gtm.pool.PoolCollection(gtm)[source]

v11.x BIG-IP® GTM pool collection

class f5.bigip.tm.gtm.pool.Pool(pool_s)[source]

v11.x BIG-IP® GTM pool resource

class f5.bigip.tm.gtm.pool.PoolOrganizingCollection(gtm)[source]

v12.x GTM pool is an OC.

class f5.bigip.tm.gtm.pool.A_s(pool)[source]

v12.x BIG-IP® A pool collection.

Class name needed changing due to ‘as’ being reserved python keyword

class f5.bigip.tm.gtm.pool.A(_as)[source]

v12.x BIG-IP®A pool resource

class f5.bigip.tm.gtm.pool.Aaaas(pool)[source]

v12.x BIG-IP® AAAA pool collection

class f5.bigip.tm.gtm.pool.Aaaa(aaaas)[source]

v12.x BIG-IP® AAAA pool resource

class f5.bigip.tm.gtm.pool.Cnames(pool)[source]

v12.x BIG-IP® CNAME pool collection

class f5.bigip.tm.gtm.pool.Cname(cnames)[source]

v12.x BIG-IP® CNAME pool resource

class f5.bigip.tm.gtm.pool.Mxs(pool)[source]

v12.x BIG-IP® MX pool collection.

class f5.bigip.tm.gtm.pool.Mx(mxs)[source]

v12.x BIG-IP® MX pool resource

class f5.bigip.tm.gtm.pool.Naptrs(pool)[source]

v12.x BIG-IP® NAPTR pool collection

class f5.bigip.tm.gtm.pool.Naptr(naptrs)[source]

v12.x BIG-IP® NAPTR pool resource

class f5.bigip.tm.gtm.pool.Srvs(pool)[source]

v12.x BIG-IP® SRV pool collection

class f5.bigip.tm.gtm.pool.Srv(naptrs)[source]

v12.x BIG-IP® SRV pool resource

region

BIG-IP® Global Traffic Manager™ (GTM®) Region module.

REST URI

http://localhost/mgmt/tm/gtm/region

GUI Path

DNS --> GSLB : Topology : Regions

REST Kind

tm:gtm:region:*

class f5.bigip.tm.gtm.region.Regions(gtm)[source]

BIG-IP® GTM Region collection

class f5.bigip.tm.gtm.region.Region(regions)[source]

BIG-IP® GTM Region resource

rule

BIG-IP® Global Traffic Manager (GTM) rule module.

REST URI

http://localhost/mgmt/tm/gtm/rule

GUI Path

DNS --> GSLB : iRules

REST Kind

tm:gtm:rule:*

class f5.bigip.tm.gtm.rule.Rules(gtm)[source]

BIG-IP® GTM rule collection

class f5.bigip.tm.gtm.rule.Rule(rule_s)[source]

BIG-IP® GTM rule resource

server

BIG-IP® Global Traffic Manager™ (GTM®) pool module.

REST URI

http://localhost/mgmt/tm/gtm/server

GUI Path

DNS --> GSLB : Servers

REST Kind

tm:gtm:server:*

class f5.bigip.tm.gtm.server.Servers(gtm)[source]

BIG-IP® GTM server collection

class f5.bigip.tm.gtm.server.Server(servers)[source]

BIG-IP® GTM server resource

class f5.bigip.tm.gtm.server.Virtual_Servers_s(server)[source]

BIG-IP® GTM virtual server sub-collection

class f5.bigip.tm.gtm.server.Virtual_Server(virtual_servers_s)[source]

BIG-IP® GTM virtual server resource

load(**kwargs)[source]

Load an already configured service into this instance.

This method uses HTTP GET to obtain a resource from the BIG-IP®.

The URI of the target service is constructed from the instance’s container and **kwargs.

kwargs typically requires the keys name and partition. this may, or may not, be true for a specific service.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args

Returns:

Resource: A Resource Instance with a populated _meta_data['uri']

exists(**kwargs)[source]

Check for the existence of the named object on the BIG-IP

Sends an HTTP GET to the URI of the named object and if it fails with a :exc:~requests.HTTPError` exception it checks the exception for status code of 404 and returns False in that case.

If the GET is successful it returns True.

For any other errors are raised as-is.

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.get method where it will be handled according to that API.

Use the method above to pass query args.

Returns:

bool: True is the object exists. False otherwise.

Raises:

requests.HTTPError: Any HTTP error that was not status code 404.

refresh(**kwargs)[source]

Use this to make the device resource be represented by self.

This method makes an HTTP GET query against the device service. This method is run for its side-effects on self. If successful the instance attribute __dict__ is replaced with the dict representing the device state. To figure out what that state is, run a subsequest query of the object like this: As with all CURDLE methods use a “requests_params” dict to pass parameters to requests.session.HTTPMETHOD. See test_requests_params.py for an example. >>> resource_obj.refresh() >>> print(resource_obj.raw)

delete(**kwargs)[source]

Delete the resource on the BIG-IP®.

Uses HTTP DELETE to delete the resource on the BIG-IP®.

After this method is called, and status_code 200 response is received instance.__dict__ is replace with {'deleted': True}

Args:
**kwargs (dict): Arbitrary number of keyword arguments.

The only current use is to pass kwargs to the requests API.

If kwargs has a requests_params key the corresponding dict will be passed to the underlying requests.session.delete method where it will be handled according to that API.

Use the method above to pass query args.

topology

BIG-IP® Global Traffic Manager™ (GTM®) Topology Records module.

REST URI

http://localhost/mgmt/tm/gtm/topology

GUI Path

DNS --> GSLB : Topology : Records

REST Kind

tm:gtm:topology:*

class f5.bigip.tm.gtm.topology.Topology_s(gtm)[source]

BIG-IP® GTM Topology collection

Due to an bug where attempts to create/modify/load/delete etc. of this resource in 12.0.0 Final, we have disabled this resource for version 12.0.0

class f5.bigip.tm.gtm.topology.Topology(topology_s)[source]

BIG-IP® GTM Topology resource

create(**kwargs)[source]

Custom method to implement checking of kwarg[‘name’] contents.

::Warning:

Be sure to format the gtm topology OID string using the following rules:

  1. Use only a single space between each item in the topology string.

2) Use a fully-pathed name for datacenter, isp, region, and pool objects.

For example: “ldns: subnet 11.11.11.0/24 server: datacenter /Common/DC”

load(**kwargs)[source]

Custom method to implement checking of kwarg[‘name’] contents.

exists(**kwargs)[source]

Providing a partition is not necessary on topology; causes errors

refresh(**kwargs)[source]

Refresh is not supported for Topology

Raises:

UnsupportedOperation

modify(**patch)[source]

Modify is not supported for Topology

Raises:

UnsupportedOperation

update(**kwargs)[source]

Update is not supported for Topology

Raises:

UnsupportedOperation

wideip

BIG-IP® Global Traffic Manager™ (GTM®) pool module.

REST URI

http://localhost/mgmt/tm/gtm/wideip

GUI Path

DNS --> GSLB : Wide IPs

REST Kind

tm:gtm:pools:*

class f5.bigip.tm.gtm.wideip.Wideips(container)[source]

BIG-IP® GTM WideIP factory

The GTM WideIP factory object is used to provide a consistent user experience across the SDK, while supporting the breaking changes in the BIG-IP APIs.

Between the 11.x and 12.x releases of BIG-IP, the REST endpoint for WideIP changed from a Collection to an OrganizingCollection. The result is that breaking changes occurred in the API.

This breakage led to a discussion on naming conventions because there appeared to be a conflict now. For example, depending on your version, only one of the following would work.

For 11.x,

tm.gtm.wideips.wideip.load(name=’foo’)

For 12.x,

tm.gtm.wideips.a_s.a.load(name=’foo’)

but not both. To stick with a consistent user experience, we decided to override the __new__ method to support both examples above. The SDK automatically detects which one to use based on the BIG-IP you are communicating with.

class f5.bigip.tm.gtm.wideip.WideipOrganizingCollection(gtm)[source]

v12.x GTM WideIP is an OC.

class f5.bigip.tm.gtm.wideip.A_s(wideip)[source]

v12.x BIG-IP® A wideip collection.

Class name needed changing due to ‘as’ being reserved python keyword

class f5.bigip.tm.gtm.wideip.A(_as)[source]

v12.x BIG-IP®A wideip resource

class f5.bigip.tm.gtm.wideip.Aaaas(wideip)[source]

v12.x BIG-IP® AAAA wideip collection

class f5.bigip.tm.gtm.wideip.Aaaa(aaaas)[source]

v12.x BIG-IP® AAAA wideip resource

class f5.bigip.tm.gtm.wideip.Cnames(wideip)[source]

v12.x BIG-IP® CNAME wideip collection

class f5.bigip.tm.gtm.wideip.Cname(cnames)[source]

v12.x BIG-IP® CNAME wideip resource

class f5.bigip.tm.gtm.wideip.Mxs(wideip)[source]

v12.x BIG-IP® MX wideip collection.

class f5.bigip.tm.gtm.wideip.Mx(mxs)[source]

v12.x BIG-IP® MX wideip resource

class f5.bigip.tm.gtm.wideip.Naptrs(wideip)[source]

v12.x BIG-IP® NAPTR wideip collection

class f5.bigip.tm.gtm.wideip.Naptr(naptrs)[source]

v12.x BIG-IP® NAPTR wideip resource

class f5.bigip.tm.gtm.wideip.Srvs(wideip)[source]

v12.x BIG-IP® SRV wideip collection

class f5.bigip.tm.gtm.wideip.Srv(naptrs)[source]

v12.x BIG-IP® SRV wideip resource

class f5.bigip.tm.gtm.wideip.WideipCollection(gtm)[source]

v11.x BIG-IP® GTM wideip collection

class f5.bigip.tm.gtm.wideip.Wideip(wideips)[source]

v11.x BIG-IP® GTM pool resource