Article 287 [source]

Spanish Criminal Code
English translation

1. To prosecute the offenses set forth in Section 3 of this Chapter, except those set forth in Articles 284 and 285, a complaint from the aggrieved party or their legal representatives is required. When the aggrieved party is a minor, a person with a disability in need of special protection, or a vulnerable person, the Public Prosecutor's Office may also file a complaint.

2. The complaint required in the preceding paragraph is not necessary when the commission of the offense affects the general interest or a plurality of persons.