f5-common-python icon indicating copy to clipboard operation
f5-common-python copied to clipboard

RFE: Support for specifying auth token to use

Open jbnance opened this issue 7 years ago • 1 comments

ICR added the ability to specify the auth token to use in https://github.com/F5Networks/f5-icontrol-rest-python/pull/138.

Please add support for this parameter to the SDK.

Using:

f5-icontrol-rest==1.3.11
f5-sdk==3.0.20

I get the following:

mgmt = ManagementRoot(
    hostname,
    username,
    password,
    token=True,
    token_to_use='my_big_token_from_another_connection',
)

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File ".../f5env/lib/python3.6/site-packages/f5/bigip/__init__.py", line 169, in __init__
    hostname, username, password, **kwargs
  File ".../f5env/lib/python3.6/site-packages/f5/bigip/__init__.py", line 55, in __init__
    hostname, username, password, **kwargs
  File ".../f5env/lib/python3.6/site-packages/f5/bigip/__init__.py", line 72, in parse_arguments
    raise TypeError('Unexpected **kwargs: %r' % kwargs)
TypeError: Unexpected **kwargs: {'token_to_use': 'my_big_token_from_another_connection'}

jbnance avatar Sep 25 '18 22:09 jbnance

PR #1511 added to try and get this rolling

jbnance avatar Sep 25 '18 22:09 jbnance