govultr icon indicating copy to clipboard operation
govultr copied to clipboard

[Enhancement] - Allow multiple filters per request

Open ribtoks opened this issue 3 years ago • 3 comments

Describe the bug I cannot receive a list of instances filtered with tag and region using ListInstances API, because I'm receiving an error "Only one filter per request is allowed.". This error is frustrating to me because:

  • to achieve what I want, now I would need to create artificial tags that will consist of my old tags + concatenated region field (which is a "workaround engineering" that will require additional maintenance effort)
  • I do not understand such restriction necessity

To Reproduce Steps to reproduce the behavior: Construct govultr.ListOptions specifying Tag and Region in a single object.

Expected behavior A ListInstances API call succeeds and returns instances in the specified region with the specified tag.

Screenshots

Desktop (please complete the following information where applicable:

  • OS: -
  • Language Version Go 1.17
  • Browser -
  • Version -

Additional context

ribtoks avatar May 08 '22 08:05 ribtoks

@ribtoks We'll look into this for you

ddymko avatar May 08 '22 11:05 ddymko

@ribtoks This error looks like it is coming back from API. We'll have to take a look at the API. I'll make an internal ticket to dig into this on the API side and get back to you.

ddymko avatar May 08 '22 12:05 ddymko

@ddymko Thank you very much!

ribtoks avatar May 08 '22 13:05 ribtoks