Initial split of internal and external api types.

As I understand it, anything where the fields are identical works.  (obviously this function will need to become more sophisticated)