How to restrict graphql query to return published content

i want a graphql api that only return contents that publish field = 1 and not return contents that have publish = 0.
This means that the client can not retrieve contents at all whose public field value = 0.

Does anyone have an idea about this ?

You would do this with@auth rules.