def parse_interfaces(interfaces):
parsed_interfaces = collections.defaultdict(dict)<EOL>for m, d in iteritems(interfaces):<EOL><INDENT>app, func = m.split('<STR_LIT:.>', <NUM_LIT:1>)<EOL>method = parsed_interfaces[app][func] = {}<EOL>method['<STR_LIT>'] = ['<STR_LIT>', '<STR_LIT>']<EOL>method['<STR_LIT>'] = '<STR_LIT:POST>'<EOL>method['<STR_LIT>'] = {}<EOL>method['<STR_LIT>'] = {}<EOL>for name, type_info in iteritems(dict(d['<STR_LIT>'])):<EOL><INDENT>optionality = '<STR_LIT>'<EOL>param_type = '<STR_LIT:string>'<EOL>type_info = TYPE_INFO_COMMENT_RE.sub('<STR_LIT>', type_info)<EOL>info_pieces = TYPE_INFO_SPLITTER_RE.findall(type_info)<EOL>for info_piece in info_pieces:<EOL><INDENT>if info_piece in ('<STR_LIT>', '<STR_LIT>'):<EOL><INDENT>optionality = info_piece<EOL><DEDENT>elif info_piece == '<STR_LIT>':<EOL><INDENT>optionality = '<STR_LIT>'<EOL>param_type = '<STR_LIT:string>'<EOL><DEDENT>elif info_piece == '<STR_LIT>':<EOL><INDENT>optionality = '<STR_LIT>'<EOL><DEDENT>elif info_piece == '<STR_LIT>':<EOL><INDENT>optionality = '<STR_LIT>'<EOL><DEDENT>else:<EOL><INDENT>param_type = info_piece<EOL><DEDENT><DEDENT>method[optionality][name] = map_param_type(param_type)<EOL><DEDENT><DEDENT>return dict(parsed_interfaces)<EOL>
Parse the conduit.query json dict response
This performs the logic of parsing the non-standard params dict
    and then returning a dict Resource can understand