theapsgroup / steampipe-plugin-freshservice

Use SQL to instantly query FreshService tickets, assets and more. Open source CLI. No DB required.
https://hub.steampipe.io/plugins/theapsgroup/freshservice
Apache License 2.0
5 stars 2 forks source link

freshservice_ticket query tries to fetch all tickets unless using specific fields in where clause #46

Open Stinjul opened 3 months ago

Stinjul commented 3 months ago

I've been messing around with this plugin and noticed that unless I'm filtering on either requester_id or email in the where clause the plugin tries to fetch all tickets in our freshservice instance (which seems to take a very long time in our case).

Could you add support for the other filterable fields or is this not possible?

graza-io commented 1 week ago

@Stinjul

Firstly, apologies for not responding to this sooner, honestly I'd simply just missed the notification.

This shouldn't be too difficult to extend albeit requires some changes to the underlying FS SDK.

Namely the ListTicketOptions needs to be extended here to support additional properties.

These fields could then be added as quals on the table code and passed through to the underlying SDK.

I'll assign this to myself and attempt to pick it up during some downtime unless you wish to take a stab at it yourself? :)