01-27-2023 09:44 PM - edited 01-27-2023 11:54 PM
Hi Community,
I have trouble getting the AXLAPI getLdapSyncStatus to work.
Other methods using my "axl_service" work as expected.
I keep getting "TypeError: Choice elements only work with keyword arguments".
Here is the problematic part of my code. Python, and Zeep:
Solved! Go to Solution.
01-29-2023 07:09 AM
The code fragment you listed would be how it is defined in the AXL toolkit. You would actually use like this.
client = Client(wsdl=wsdl_file, transport=transport, plugins=[history], settings=settings)
axl = client.create_service(binding_name, axl_address)
ldap_resp = axl.getLdapSyncStatus(name='my-ldap-dir')
01-29-2023 07:09 AM
The code fragment you listed would be how it is defined in the AXL toolkit. You would actually use like this.
client = Client(wsdl=wsdl_file, transport=transport, plugins=[history], settings=settings)
axl = client.create_service(binding_name, axl_address)
ldap_resp = axl.getLdapSyncStatus(name='my-ldap-dir')
02-22-2023 11:21 AM
Thanks, Elloit.
To add a bit of context, my other working commands are "list' commands. Thus they take two arguments which can be a dict. However, the "get" command only takes one argument and I guess cannot be a complex data type such as a dict.
So, your answer worked.
In trying to keep my code format consistent, I used **searchCriteria to allow Python to unpack the dict back to the key:vlaue pair you mentioned.
Thanks again for responding.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide