If statement in filter condition

Hi.

I have a scenario that has a unique identifier for my clients called “ServiceID”. The scenario does a query to my DB and gets all client info and their associated unique identifier (ServiceID).

However, there are times where I just want to run the scenario for a single client. I can do this manually by setting a filter after my DB call to filter just where the ServiceID matches some value I type in (see below image). Works great.

Can you help me think through ways to automate this filter when needed? I am considering using a passed in parameter on the initial Webhook.

The statement would need to be something like…

If the passed in parameter (ServiceID) exists (or is not blank) then apply no filter and process all client records.
Else if the passed in parameter (ServiceID) exists, filter the DB results by that value.

Here is how the filter works manually. It asks each record if the ServiceID equals the manually input value of 1234

Can I pass in a ServiceID variable into the webhook that I can use to filter in the same way, but if no variable exists, just process the entire DB?