def __item_descriptor(self, config):
descriptor = {<EOL>'<STR_LIT>': '<STR_LIT>',<EOL>'<STR_LIT>': {<EOL>'<STR_LIT>': '<STR_LIT>'<EOL>'<STR_LIT>',<EOL>'<STR_LIT>': '<STR_LIT>'<EOL>'<STR_LIT>',<EOL>},<EOL>'<STR_LIT>': True,<EOL>}<EOL>description = config.get('<STR_LIT:description>')<EOL>root_url = config.get('<STR_LIT:root>')<EOL>name = config.get('<STR_LIT:name>')<EOL>version = config.get('<STR_LIT>')<EOL>relative_path = '<STR_LIT>'.format(name, version)<EOL>if description:<EOL><INDENT>descriptor['<STR_LIT:description>'] = description<EOL><DEDENT>descriptor['<STR_LIT:name>'] = name<EOL>descriptor['<STR_LIT:version>'] = version<EOL>descriptor['<STR_LIT>'] = '<STR_LIT>'.format(relative_path)<EOL>root_url_port = urlparse.urlparse(root_url).port<EOL>original_path = self.__request.reconstruct_full_url(<EOL>port_override=root_url_port)<EOL>descriptor['<STR_LIT>'] = '<STR_LIT>'.format(<EOL>original_path, name, version)<EOL>if name and version:<EOL><INDENT>descriptor['<STR_LIT:id>'] = '<STR_LIT>'.format(name, version)<EOL><DEDENT>return descriptor<EOL>
Builds an item descriptor for a service configuration.

        Args:
          config: A dictionary containing the service configuration to describe.

        Returns:
          A dictionary that describes the service configuration.