Best way to split UD between API and client?

#1

How do I best connect to the “remote api” in UD?

just use invoke-restmethod?
or is where are way for a smarter way builtin?