Ah no, this isn't for a store front. It's for an app (hence posting in the API's thread) where I simply need to know how many products were returned for a given keyword.
I'm really surprised that it isn't possible to filter the product API results by keyword to get the same results as the store front.
That suggestion would be great if it were possible to add a liquid template via the API but again, I'm guessing that's not possible either.
My App should be as automated as possible, I can't ask store owners to create templates for my app to function.