How are you defining that model and methods today? Are they already in the tech / lang you use or are you using some translation like protobuf or openapi?
(curiosity as I'm building a tool on top of CUE that combines it with notions of data models and code gen, and I'm always keen to learn more about the things people do today)