I have created a Groovy client for the TestRail API and like to share it, in case someone finds it interesting and/or useful.
The repo is here: https://github.com/dbac2002/testrail-groovy-client and it is work in progress.
The idea is to provide an intuitive DSL for accessing the TestRail API.
With the client, one can create something like the following:
connect '<server_url>' login '<user>', '<password_or_key>' // prints the name of user with id 7 show('name') of user(7) // prints the title of test with id 590 show('title') of test(590) // prints the id of the test case in project 11, suite 14 and section 122 show('id') of testcases(project(11), suite(14), section(122)) // print the name of completed milestones in project with id 7 show('name') of milestones(project(7), 'completed') // get the user with id 7 def user7 = get user(7) // get the test case with id 308 def testcase308 = get testcase(308)
Currently the client only supports GET requests, POST is coming in the next days. Also not all request filters are currently implemented, this will also follow.
Feel free to use it, work it, create pull requests etc.