Jump to content

Export Request Question Responses via API


Recommended Posts

Hi all,

I am trying to automate the export of request data and more importantly the responses to questsions using APIs.

So far I can get all requests that match search query using : "apps/com.hornbill.servicemanager/Requests" "searchRequests"

I can then loop through each request getting various details using : "apps/com.hornbill.servicemanager/Requests" "smGetReqDetails2"

This enables me to return the number of questions completed but not the actual responses. Is there another API that has this feature that I can't find?

Many Thanks

Ben

 

 

Link to comment
Share on other sites

Hi @Ben Paddick,

I'm good thanks, hope you are too.

This is the API you're after: https://api.hornbill.com/apps/com.hornbill.servicemanager/Questions?op=queryExec

And an example of its use, to return paginated questions and answers for a specific request (SR00000513 in this example): 

<methodCall service="apps/com.hornbill.servicemanager/Questions" method="queryExec">
	<params>
		<queryName>getRequestQuestions</queryName>
		<requestId>SR00000513</requestId>
		<rowstart>0</rowstart>
		<limit>10</limit>
		<resultType>allData</resultType>
		<answerType>all</answerType>
	</params>
</methodCall>

Cheers,

Steve

Link to comment
Share on other sites

24 minutes ago, Steve G said:

Hi @Ben Paddick,

I'm good thanks, hope you are too.

This is the API you're after: https://api.hornbill.com/apps/com.hornbill.servicemanager/Questions?op=queryExec

And an example of its use, to return paginated questions and answers for a specific request (SR00000513 in this example): 


<methodCall service="apps/com.hornbill.servicemanager/Questions" method="queryExec">
	<params>
		<queryName>getRequestQuestions</queryName>
		<requestId>SR00000513</requestId>
		<rowstart>0</rowstart>
		<limit>10</limit>
		<resultType>allData</resultType>
		<answerType>all</answerType>
	</params>
</methodCall>

Cheers,

Steve

@Steve G thank you so much!!! 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...