Core Api Code for TypeStruct