def METHOD_NAME(video, apikey=None, **kwargs):
    """Refine a video by searching `OMDb API <http://omdbapi.com/>`_.
    Several :class:`~subliminal.video.Episode` attributes can be found:
      * :attr:`~subliminal.video.Episode.series`
      * :attr:`~subliminal.video.Episode.year`
      * :attr:`~subliminal.video.Episode.series_imdb_id`
    Similarly, for a :class:`~subliminal.video.Movie`:
      * :attr:`~subliminal.video.Movie.title`
      * :attr:`~subliminal.video.Movie.year`
      * :attr:`~subliminal.video.Video.imdb_id`
    """
    if not apikey:
        logger.warning('No apikey. Skipping omdb refiner.')
        return
    omdb_client.session.params['apikey'] = apikey
    if isinstance(video, Episode):
        # exit if the information is complete
        if video.series_imdb_id:
            logger.debug('No need to search')
            return
        # search the series
        results = search(video.series, 'series', video.year)
        if not results:
            logger.warning('No results for series')
            return
        logger.debug('Found %d results', len(results))
        # filter the results
        results = [r for r in results if video.matches(r['Title'])]
        if not results:
            logger.warning('No matching series found')
            return
        # process the results
        found = False
        for result in sorted(results, key=operator.itemgetter('Year')):
            if video.original_series and video.year is None:
                logger.debug('Found result for original series without year')
                found = True
                break
            if video.year == int(result['Year'].split(u'\u2013')[0]):
                logger.debug('Found result with matching year')
                found = True
                break
        if not found:
            logger.warning('No matching series found')
            return
        # add series information
        logger.debug('Found series %r', result)
        video.series = result['Title']
        video.year = int(result['Year'].split(u'\u2013')[0])
        video.series_imdb_id = result['imdbID']
    elif isinstance(video, Movie):
        # exit if the information is complete
        if video.imdb_id:
            return
        # search the movie
        results = search(video.title, 'movie', video.year)
        if not results:
            logger.warning('No results for movie')
            return
        logger.debug('Found %d results', len(results))
        # filter the results
        results = [r for r in results if video.matches(r['Title'])]
        if not results:
            logger.warning('No matching movie found')
            return
        # process the results
        found = False
        for result in results:
            if video.year is None:
                logger.debug('Found result for movie without year')
                found = True
                break
            if video.year == int(result['Year']):
                logger.debug('Found result with matching year')
                found = True
                break
        if not found:
            logger.warning('No matching movie found')
            return
        # add movie information
        logger.debug('Found movie %r', result)
        video.title = result['Title']
        video.year = int(result['Year'].split(u'\u2013')[0])
        video.imdb_id = result['imdbID']