How to get tickets by status of a user?

  • 10 January 2015
  • 3 replies
  • 52 views

We are building a custom CMS platform and have chosen to go with Freshdesk as our support system.


Ultimately, we'd like users to be able to stay in our dashboard to manage their support needs.  We feel that this will reduce confusion with our users as they would only need to manage one login (the one to our CMS) and not two (an additional login for Freshdesk).


Using the API, we'd like to be able to do simple tasks like show tickets for a given user (open/closed/all), create a new ticket, and reply to an existing ticket.


Right now, we have our users make a "support profile" in our system before they can interact with the other features.  This records some data on our end, makes an API call to create a new contact, and attaches the user ID that comes back to their account.  This saved ID is then used to make the API calls throughout the rest of the dashboard.


In our current setup, we are basically using an "API" user to make all of these requests, and we send over "requester_id" based on information we have saved for the user from the result of the API create contact call.


This works well except for when it comes to listing tickets.


We have defined custom view in this API account and use them with the "Custom Ticket Views" method of the tickets list API (http://freshdesk.com/api#view_all_ticket).


This filters out tickets based on our statues, but it doesn't do it for a user.  If I try just passing in "requester_id" as a query parameter on this call, it performs a "Requester" method call instead of the "Custom Ticket View" call (I am calling the "Custom Ticket View" endpoint, but it appears that the presence of the "requester_id" in it's query string forces it to just return all tickets for that user and ignore the view being passed altogether).



TL;DR

Is there any way with this setup to pass the API a user ID and a view or some other setting to obtain tickets just for that user but filtered by things like statuses, etc?


I feel that this would be a common use case: "show me all tickets for user X with status Y".  Ideally, I think that these users would have their own accounts and would be using their API credentials, but due to the fact that this requires people to actually sign up on Freshdesk, it's not an ideal situation for us.


Thanks for any help!



This topic has been closed for comments

3 replies

Userlevel 4
Badge +12

Hi,




It is now possible to query for tickets using requester email and also the option to filter tickets by custom views is available . For more information,read API V2 documentation




Cheers!


We too are trying to request tickets by contact through the API and filter them by status.


Userlevel 4
Badge +8

Hey Justin,


I am going to convert this topic into a ticket so that we can discuss this in more detail.


Anna