Dynamic client-go

I would like to use the dynamic client-go to discover dynamically a GVK.

For instance kubectl get pod my-pod does the same thing. However, there is a lack of examples on how to use the RESTMapper and how it works

Does anyone know how to create a RESTMapper to request the GVR?


I used it to make a discord bot. Here is the repo

Thanks for your reply, but it’s not what I’m asking for.

Ah sorry about the misunderstanding!