Skip to content

Commit 7a0259e

Browse files
author
Thomas v.d. Jagt
committed
added update_interface_connection method. setup to new version 0.0.7
1 parent 39c707b commit 7a0259e

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

netbox/dcim.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -387,9 +387,18 @@ def create_interface_connection(self, interface_a, interface_b, **kwargs):
387387
return self.netbox_con.post('/dcim/interface-connections/', required_fields, **kwargs)
388388

389389
def delete_interface_connection(self, interface_connection_id):
390-
"""Delete interface by id
390+
"""Delete interface-connection by id
391391
392-
:param interface_connection_id: id of interface to remove
392+
:param interface_connection_id: id of interface-connection to remove
393393
:return: bool True if successful otherwise raise DeleteException
394394
"""
395395
return self.netbox_con.delete('/dcim/interface-connections/', interface_connection_id)
396+
397+
def update_interface_connection(self, interface_connection_id, **kwargs):
398+
"""Update interface
399+
400+
:param interface_connection_id: interface_connection to update
401+
:param kwargs: requests body dict
402+
:return: bool True if successful otherwise raise UpdateException
403+
"""
404+
return self.netbox_con.patch('/dcim/interface-connections/', interface_connection_id, **kwargs)

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ def readme():
1111
return f.read()
1212

1313
setup(name='python-netbox',
14-
version='0.0.5',
14+
version='0.0.7',
1515
description='Python NetBox Client',
1616
long_description=readme(),
1717
python_requires='>=3',

0 commit comments

Comments
 (0)