Search

Problem with Dynamic Ticket Reports

Subscribe to Problem with Dynamic Ticket Reports 3 post(s)

 
Dave K.

I’m using PHP/cURL to send an HTTP/GET request via cURL to the api/v1/ticket_reports/dynamic service. I’m sending an XML payload similar to the following:

testingprojectcreated_atnumberstatus-neq-Resolved

The report I get back appears to not have the requested modifications applied. Am I doing something wrong?

 
Dave K.

It seems like the request is completely ignoring any parameters that I send other than title. If I send the xml payload, it ignores everything. If I use the URL method, it only uses the title parameter. Surely this isn’t a problem with what I’m doing? If it is, I’m happy to know what it is. :)

 
David C.

Dave,

Here are two ways to request the same report using curl from the command line:

1) Using the query string method:

curl -i -u myusername:password -X GET -H 'Accept: application/xml' 'https://mysubdomain.unfuddle.com/projects/12345/ticket_reports/dynamic.xml?title=Closed+Tickets&conditions_string=status-eq-closed'

2) Sending XML with the request:

curl -i -u myusername:password -X GET -H 'Content-type: application/xml' -H 'Accept: application/xml' -d "Closed Ticketsstatus-eq-closed" 'https://mysubdomain.unfuddle.com/projects/12345/ticket_reports/dynamic.xml'

You should note that if you are sending XML with the request, you need to specify the content-type header in your request so the request body is handled correctly.