Lambda/Custom Resolver Filtering allowed or not?

How can you parse the filter to the lambda to write the queries in the lambda script? Is this possible?