riboseinc / digicert

Ruby bindings for the Digicert Services API
https://www.digicert.com/services/v2/documentation
MIT License
8 stars 10 forks source link

Add query filter support for digicert resources #120

Closed abunashir closed 7 years ago

abunashir commented 7 years ago

Digicert has undocumented support to filter resources, and this commit adds the query filter support to our .all action, so if any of the class included this module then they will have access to filter results by passing the filters hash.

To make it more easier we have also added a wrapper interface around the .all interface, which will work exactly same but will wrap the provided arguments as filters key as pass those to the .all interface.

Digicert::Order.filter(status: "approved")

# Similar functionality with `.all` interface 
Digicert::Order.all(filters: { status: "approved" })

Reference: Issue #100