<rss version="2.0" xmlns:a10="http://www.w3.org/2005/Atom"><channel><title>Inflectra Customer Forums: How to call SpiraTest API with Python? (Thread)</title><description>  I write a Python code to call SpiraTest API TestRun_CreateFromTestCases , but it doesn't work.  The code,  from suds.client import Client         client = Client("http://172.16.127.101/SpiraTest/Services/v3_0/ImportExport.svc?wsdl")   client.service.Connection_Authenticate("w9504102","password")   client.service.Connection_ConnectToProject(6)      client.service.TestRun_CreateFromTestCases(180)    It always errors as below,  C:\temp&gt;python TestRun_CreateFromTestCases.py No handlers could be found for logger "suds.client" Traceback (most recent call last):   File "TestRun_CreateFromTestCases.py", line 10, in       client.service.TestRun_CreateFromTestCases(180)   File "build\bdist.win-amd64\egg\suds\client.py", line 542, in __call__   File "build\bdist.win-amd64\egg\suds\client.py", line 602, in invoke   File "build\bdist.win-amd64\egg\suds\client.py", line 649, in send   File "build\bdist.win-amd64\egg\suds\client.py", line 702, in failed   File "build\bdist.win-amd64\egg\suds\bindings\binding.py", line 265, in get_fault suds.WebFault: Server raised fault: 'The formatter threw an exception while trying to deserialize the message: There was an erro ile trying to deserialize parameter https://www.inflectra.com/SpiraTest/Services/v3.0/:testCaseIds. The InnerException message wa rror in line 1 position 368. Expecting state 'Element'.. Encountered 'Text'  with name '', namespace ''. '.  Please see InnerExc on for more details.'  Can anyone guide me how to do it?  Thanks,  Jack Fan      </description><language>en-US</language><copyright>(C) Copyright 2006-2026 Inflectra Corporation.</copyright><managingEditor>support@inflectra.com</managingEditor><category domain="http://www.dmoz.org">/Computers/Software/Project_Management/</category><category domain="http://www.dmoz.org">/Computers/Software/Quality_Assurance/</category><generator>KronoDesk</generator><a10:contributor><a10:email>support@inflectra.com</a10:email></a10:contributor><a10:id>http://www.inflectra.com/kronodesk/forums/threads</a10:id><ttl>120</ttl><link>/Support/Forum/spiratest/issues-questions/226.aspx</link><item><guid isPermaLink="false">threadId=226</guid><author>Jack Fan (jack_fan6038@hotmail.com)</author><title>How to call SpiraTest API with Python?</title><description>  I write a Python code to call SpiraTest API TestRun_CreateFromTestCases , but it doesn't work.  The code,  from suds.client import Client         client = Client("http://172.16.127.101/SpiraTest/Services/v3_0/ImportExport.svc?wsdl")   client.service.Connection_Authenticate("w9504102","password")   client.service.Connection_ConnectToProject(6)      client.service.TestRun_CreateFromTestCases(180)    It always errors as below,  C:\temp&gt;python TestRun_CreateFromTestCases.py No handlers could be found for logger "suds.client" Traceback (most recent call last):   File "TestRun_CreateFromTestCases.py", line 10, in       client.service.TestRun_CreateFromTestCases(180)   File "build\bdist.win-amd64\egg\suds\client.py", line 542, in __call__   File "build\bdist.win-amd64\egg\suds\client.py", line 602, in invoke   File "build\bdist.win-amd64\egg\suds\client.py", line 649, in send   File "build\bdist.win-amd64\egg\suds\client.py", line 702, in failed   File "build\bdist.win-amd64\egg\suds\bindings\binding.py", line 265, in get_fault suds.WebFault: Server raised fault: 'The formatter threw an exception while trying to deserialize the message: There was an erro ile trying to deserialize parameter https://www.inflectra.com/SpiraTest/Services/v3.0/:testCaseIds. The InnerException message wa rror in line 1 position 368. Expecting state 'Element'.. Encountered 'Text'  with name '', namespace ''. '.  Please see InnerExc on for more details.'  Can anyone guide me how to do it?  Thanks,  Jack Fan      </description><pubDate>Wed, 04 Jan 2012 09:03:13 -0500</pubDate><a10:updated>2022-01-03T01:26:52-05:00</a10:updated><link>/Support/Forum/spiratest/issues-questions/226.aspx</link></item><item><guid isPermaLink="false">messageId=441</guid><author>David J (adam.sandman+support@inflectra.com)</author><title>You need to pass in an array of test cases to the function not just a single ID. If you look at the </title><description>You need to pass in an array of test cases to the function not just a single ID. If you look at the API signature, that is what it is expecting.</description><pubDate>Thu, 05 Jan 2012 16:27:57 -0500</pubDate><a10:updated>2012-01-05T16:27:57-05:00</a10:updated><link>/Support/Forum/spiratest/issues-questions/226.aspx#reply441</link></item></channel></rss>