URGENT-Problem with Frappe API

i’m using erpnext v12 and facing a problem that i can read all data using mydomain.com/api/resource/:doctype without auth.

how can I fix this ?

This seems unlikely, unless the role “Guest” has read permissions on your DocType. You can check and adjust this via Role Permission Manager.

Btw, v12 is no longer supported. Consider upgrading to a supported major version (currently v14+).

no this is happening and i was able to PayPass the problem by hard coding the users allowed to use the API in the API file, but I’m looking for the reason so I can resolve it completely , this problem appear at one server from many servers running erpnext