Initial split of internal and external api types.

http://play.golang.org/p/8N7pqWMQrx