Cakephp3休息参数/过滤器

I use CakePHP 3 and try to create a REST access.

When connecting to homepage.tld/invoices.json I get all invoices (which is correct).

But now I'd like to use parameter/filter to reduce the output and fetch specific invoices:

homepage.tld/invoices.json?id=5 <-- only the invoice with id 5

homepage.tld/invoices.json?customer_id=3 <-- all invoices with a customer_id=3

Is there a simple solution or is manual programming required?

Is there a simple solution or is manual programming required?

Yes, you need to write code for that.

But you can use the friends of cake search plugin for that, it will make it easy and less repetitive.