diff --git a/tools/sdbusplus/property.py b/tools/sdbusplus/property.py
index bdff93d..bcb50d9 100644
--- a/tools/sdbusplus/property.py
+++ b/tools/sdbusplus/property.py
@@ -11,6 +11,32 @@
 
         super(Property, self).__init__(**kwargs)
 
+    """ Return a conversion of the cppTypeName valid as a function parameter.
+        Currently only 'enum' requires conversion.
+    """
+    def cppTypeParam(self, interface, server=True):
+        if self.cppTypeName.startswith("enum<"):
+            # strip off 'enum<' and '>'
+            r = self.cppTypeName.split('>')[0].split('<')[1]
+
+            # self. means local type.
+            if r.startswith("self."):
+                return r.split('self.')[1]
+
+            r = r.split('.')
+            r.insert(-2, "server" if server else "client")
+            r = "::".join(r)
+            return r
+        return self.cppTypeName
+
+    """ Return a conversion of the cppTypeName valid as it is read out of a
+        message.  Currently only 'enum' requires conversion.
+    """
+    def cppTypeMessage(self, interface):
+        if self.cppTypeName.startswith("enum<"):
+            return "std::string"
+        return self.cppTypeName
+
     def parse_cpp_type(self, typeName):
         if not typeName:
             return None
diff --git a/tools/sdbusplus/templates/interface.mako.server.cpp b/tools/sdbusplus/templates/interface.mako.server.cpp
index 0b71244..b17ddda 100644
--- a/tools/sdbusplus/templates/interface.mako.server.cpp
+++ b/tools/sdbusplus/templates/interface.mako.server.cpp
@@ -35,7 +35,8 @@
     % endfor
 
     % for p in interface.properties:
-${p.cppTypeName} ${classname}::${p.camelCase}() const
+auto ${classname}::${p.camelCase}() const ->
+        ${p.cppTypeParam(interface.name)}
 {
     return _${p.camelCase};
 }
@@ -53,7 +54,8 @@
     return true;
 }
 
-${p.cppTypeName} ${classname}::${p.camelCase}(${p.cppTypeName} value)
+auto ${classname}::${p.camelCase}(${p.cppTypeParam(interface.name)} value) ->
+        ${p.cppTypeParam(interface.name)}
 {
     if (_${p.camelCase} != value)
     {
@@ -73,7 +75,7 @@
 
     auto o = static_cast<${classname}*>(context);
 
-    decltype(_${p.camelCase}) v{};
+    ${p.cppTypeMessage(interface.name)} v{};
     m.read(v);
     o->${p.camelCase}(v);
 
@@ -86,7 +88,7 @@
 {
 static const auto _property_${p.name} =
     utility::tuple_to_array(message::types::type_id<
-            ${p.cppTypeName}>());
+            ${p.cppTypeMessage(interface.name)}>());
 }
 }
     % endfor
diff --git a/tools/sdbusplus/templates/interface.mako.server.hpp b/tools/sdbusplus/templates/interface.mako.server.hpp
index 954742d..5a67a43 100644
--- a/tools/sdbusplus/templates/interface.mako.server.hpp
+++ b/tools/sdbusplus/templates/interface.mako.server.hpp
@@ -39,6 +39,15 @@
          */
         ${classname}(bus::bus& bus, const char* path);
 
+    % for e in interface.enums:
+        enum class ${e.name}
+        {
+        % for v in e.values:
+            ${v.name},
+        % endfor
+        };
+    % endfor
+
     % for m in interface.methods:
 ${ m.cpp_prototype(loader, interface=interface, ptype='header') }
     % endfor
@@ -49,9 +58,10 @@
 
     % for p in interface.properties:
         /** Get value of ${p.name} */
-        virtual ${p.cppTypeName} ${p.camelCase}() const;
+        virtual ${p.cppTypeParam(interface.name)} ${p.camelCase}() const;
         /** Set value of ${p.name} */
-        virtual ${p.cppTypeName} ${p.camelCase}(${p.cppTypeName} value);
+        virtual ${p.cppTypeParam(interface.name)} \
+${p.camelCase}(${p.cppTypeParam(interface.name)} value);
     % endfor
 
     private:
@@ -78,9 +88,9 @@
 
     % for p in interface.properties:
         % if p.defaultValue:
-        ${p.cppTypeName} _${p.camelCase} = ${p.defaultValue};
+        ${p.cppTypeParam(interface.name)} _${p.camelCase} = ${p.defaultValue};
         % else:
-        ${p.cppTypeName} _${p.camelCase}{};
+        ${p.cppTypeParam(interface.name)} _${p.camelCase}{};
         % endif
     % endfor
 
diff --git a/tools/sdbusplus/templates/method.mako.prototype.hpp b/tools/sdbusplus/templates/method.mako.prototype.hpp
index 12b1574..96e7390 100644
--- a/tools/sdbusplus/templates/method.mako.prototype.hpp
+++ b/tools/sdbusplus/templates/method.mako.prototype.hpp
@@ -3,7 +3,7 @@
         if len(method.returns) == 0:
             return "void"
         elif len(method.returns) == 1:
-            return method.returns[0].cppTypeName
+            return method.returns[0].cppTypeParam(interface.name)
         else:
             return "std::tuple<" + \
                    returns_as_list() + \
@@ -20,16 +20,18 @@
         return ", ".join([ p.camelCase for p in method.parameters ])
 
     def parameters_types_as_list():
-        return ", ".join([ p.cppTypeName for p in method.parameters ])
+        return ", ".join([ p.cppTypeMessage(interface.name)
+                for p in method.parameters ])
 
     def parameter(p, defaultValue=False):
-        r = "%s %s" % (p.cppTypeName, p.camelCase)
+        r = "%s %s" % (p.cppTypeParam(interface.name), p.camelCase)
         if defaultValue:
             r += default_value(p)
         return r
 
-    def returns_as_list():
-        return ", ".join([ r.cppTypeName for r in method.returns ])
+    def returns_as_list(as_param=True):
+        return ", ".join([ (r.cppTypeParam(interface.name) if as_param else
+                r.cppTypeMessage(interface.name)) for r in method.returns ])
 
     def returns_as_tuple_index(tuple):
         return ", ".join([ "std::move(std::get<%d>(%s))" % (i,tuple) \
@@ -75,7 +77,8 @@
     % if len(method.returns) != 0:
          *
         % for r in method.returns:
-         *  @return ${r.camelCase}[${r.cppTypeName}] - ${r.description.strip()}
+         *  @return ${r.camelCase}[${r.cppTypeParam(interface.name)}] \
+- ${r.description.strip()}
         % endfor
     % endif
          */
@@ -167,7 +170,7 @@
         utility::tuple_to_array(std::make_tuple('\0'));
     % else:
         utility::tuple_to_array(message::types::type_id<
-                ${ returns_as_list() }>());
+                ${ returns_as_list(as_param=False) }>());
     % endif
 }
 }
diff --git a/tools/sdbusplus/templates/signal.mako.prototype.hpp b/tools/sdbusplus/templates/signal.mako.prototype.hpp
index 7050ec3..eb5ffca 100644
--- a/tools/sdbusplus/templates/signal.mako.prototype.hpp
+++ b/tools/sdbusplus/templates/signal.mako.prototype.hpp
@@ -4,7 +4,7 @@
             join([ parameter(p, defaultValue) for p in signal.properties ])
 
     def parameter(p, defaultValue=False):
-        r = "%s %s" % (p.cppTypeName, p.camelCase)
+        r = "%s %s" % (p.cppTypeParam(interface.name), p.camelCase)
         if defaultValue:
             r += default_value(p)
         return r
@@ -13,7 +13,8 @@
         return ", ".join([ p.camelCase for p in signal.properties ])
 
     def parameters_types_as_list():
-        return ", ".join([ p.cppTypeName for p in signal.properties ])
+        return ", ".join([ p.cppTypeMessage(interface.name)
+                for p in signal.properties ])
 
     def default_value(p):
         if p.defaultValue != None:
