Insert into collection only if it exists in related one

Hello,

Suposing I want to fill a “movie collection” from an API response, but only insert the ones whoes genre exists in the “genre collection” (one to many relation with movies).

Is possible to restrict the values in Strapi? Now it inserts all movies, without considering the relation.

Thank you very much.