Whats the best way to use my existing database model tables on my extension?

I am creating a extension that will perform some actions on my model tables. I already accomplished it by connecting to it as a externa database by using the  RuntimePublic API, but I found it very cumbersome. 

  • Is the only way of doing it or Is there an API for connecting to the model tables instead of using it as an external database?

When you say "model tables" are those in the external database, or are you referring to Entities defined in an OutSystems app?