code: def search(self, index, query, **params):
          
          if index is None:
              index = 'search'
  
          options = {}
          if 'op' in params:
              op = params.pop('op')
              options['q.op'] = op
  
          options.update(params)
          url = self.solr_select_path(index, query, **options)
          status, headers, data = self._request('GET', url)
          self.check_http_code(status, [200])
          if 'json' in headers['content-type']:
              results = json.loads(bytes_to_str(data))
              return self._normalize_json_search_response(results)
          elif 'xml' in headers['content-type']:
              return self._normalize_xml_search_response(data)
          else:
              raise ValueError("Could not decode search response")
docs: Performs a search query.