code: def get_config(self, config='running-config', params=None,
                     as_string=False):
          
          if config not in ['startup-config', 'running-config']:
              raise TypeError('invalid config name specified')
  
          command = 'show %s' % config
          if params:
              command += ' %s' % params
  
          result = self.run_commands(command, 'text')
          if as_string:
              return str(result[0]['output']).strip()
  
          return str(result[0]['output']).split('\n')
docs: Retreives the config from the node
  
          This method will retrieve the config from the node as either a string
          or a list object.  The config to retrieve can be specified as either
          the startup-config or the running-config.
  
          Args:
              config (str): Specifies to return either the nodes startup-config
                  or running-config.  The default value is the running-config
              params (str): A string of keywords to append to the command for
                  retrieving the config.
              as_string (boo): Flag that determines the response.  If True, then
                  the configuration is returned as a raw string.  If False, then
                  the configuration is returned as a list.  The default value is
                  False
  
          Returns:
              This method will return either a string or a list depending on the
              states of the as_string keyword argument.
  
          Raises:
              TypeError: If the specified config is not one of either
                  'running-config' or 'startup-config'