How to check if a request came from one of the gcp services in my project

Hi! I want to figure out if a request came from one of the gcp services in my project. Is there a way to dynamically validate the origin IP somehow and figure out if it’s external or internal?

There is a predefined Google IP range https://www.gstatic.com/ipranges/goog.json

From this link https://support.google.com/a/answer/10026322?hl=en