Gets similar artists.

@param array $options An array of options.

@return \React\Promise\Promise The artist's similar artists.
356151
public function getSimilarArtists(array $options = [])
    {
        $deferred = new Deferred();

        $options = Options::buildOptions(Options::$defaultOptions, $options, $this->tidal);

        $this->http->get(
            Options::replace(Endpoints::ARTIST_SIMILAR, ['id' => $this->id]).$options
        )->then(function ($response) use ($deferred) {
            $artists = new Collection();

            foreach ($response['items'] as $artist) {
                $artists->push(new Artist(
                    $this->http,
                    $this->tidal,
                    $artist
                ));
            }

            $deferred->resolve($artists);
        }, function ($e) use ($deferred) {
            $deferred->reject($e);
        });

        return $deferred->promise();
    }
1322756
protected function getPrestaShopOptions(array $options)
    {
        $result = array(
            'query' => array(),
            'id' => 'id',
            'name' => 'name',
        );

        foreach ($options as $value => $label) {
            $result['query'][] = array(
                'id' => $value,
                'name' => $label,
            );
        }

        return $result;
    }
98773
private function getCollectionOptionsHash(array $options)
    {
        ksort($options);
        $str = '';
        foreach ($options as $option) {
            if (!$option instanceof  Serializable) {
                // All valid Collection options are BSON serializable
                continue;
            }
            $str .= serialize($option->bsonSerialize());
        }

        return md5($str);
    }
194552
public function getCollection(array $options = array())
    {
        /** @var ClientEntity[] $collection */
        $collection = $this->getRepository()->findAll();
        $resource   = new Resource($this->generateBrowseUrl(), array('count' => count($collection)));

        foreach ($collection as $element) {
            $resource->setEmbedded('client', $this->createResourceFromClient($element));
        }

        return $resource;
    }
231735
public function follow(array $options = [])
    {
        $url = $this->expand($options);
        try {
            return new CollectionDocJson($url, $this->_auth);
        } catch (NotFoundException $e) {
            return null;
        }
    }
156988
public static function find($options = [])
    {
        $options = Set::extend(static::query(), $options);
        $schema = static::definition();
        return $schema->query(['query' => $options] + ['finders' => static::finders()]);
    }
729284
public function getBinary($options = [])
    {
        $options['quality'] = isset($options['quality']) ? $options['quality'] : self::QUALITY;

        return $this->image->get($this->getFormat(), $options);
    }
1086721
public function similarityLookup($asin)
  {
    $params = $this->buildRequestParams('SimilarityLookup', array(
      'ItemId' => $asin
    ));

    return $this->returnData(
      $this->performSoapRequest("SimilarityLookup", $params)
    );
  }
528934
public function getUserTasks($options=array()){

        $data = array();
        

        $data = array_merge($data, $options);

        return $this->request($this->taskQueryUrl, $data);
    }
862485
public function getAlbums(array $options = [])
    {
        $deferred = new Deferred();

        // For some reason, TIDAL returns 404 if the filter isn't caps.
        if (isset($options['filter'])) {
            $options['filter'] = strtoupper($options['filter']);
        }

        $options = Options::buildOptions(
            array_merge(Options::$defaultOptions, ['filter' => 'COMPILATIONS']),
            $options,
            $this->tidal
        );

        $this->http->get(
            Options::replace(Endpoints::ARTIST_ALBUMS, ['id' => $this->id]).$options
        )->then(function ($response) use ($deferred) {
            $albums = new Collection();

            foreach ($response['items'] as $album) {
                $albums->push(new Album(
                    $this->http,
                    $this->tidal,
                    $album
                ));
            }

            $deferred->resolve($albums);
        }, function ($e) use ($deferred) {
            $deferred->reject($e);
        });

        return $deferred->promise();
    }
250512
public function getTopArtists($methodVars)
    {
        // Check for required variables
        if (!empty($methodVars['tag'])) {
            $vars = array(
                'method' => 'tag.gettopartists',
                'api_key' => $this->auth->apiKey
            );
            $vars = array_merge($vars, $methodVars);

            if ($call = $this->apiGetCall($vars)) {
                $i = 0;
                foreach ($call->topartists->artist as $artist) {
                    $topArtists[$i]['name'] = (string) $artist->name;
                    $topArtists[$i]['tagcount'] = (string) $artist->tagcount;
                    $topArtists[$i]['url'] = (string) $artist->url;
                    $topArtists[$i]['mbid'] = (string) $artist->mbid;
                    $topArtists[$i]['streamable'] = (string) $artist->streamable;
                    $topArtists[$i]['image']['small'] = (string) $artist->image[0];
                    $topArtists[$i]['image']['medium'] = (string) $artist->image[1];
                    $topArtists[$i]['image']['large'] = (string) $artist->image[2];
                    $i++;
                }
                return $topArtists;
            } else {
                return false;
            }
        } else {
            throw new InvalidArgumentException('You must include tag variable in the call for this method');
        }
    }
806053
public function getUsers($options = [])
    {
        $query_params = [];

        if (!empty($options['from_timestamp'])) {
            $query_params['from_ts'] = $options['from_timestamp'];
        }

        if (!empty($options['limit'])) {
            $query_params['limit'] = $options['limit'];
        }

        return $this->apiRequest([
            'method' => 'GET',
            'path' => '/users',
            'jwt' => $this->getServerToken()['token'],
            'query' => $query_params
        ]);
    }
524536
public static function getList(array $options = array())
    {
        $api = new Api\GetService();
        $result = $api->doRequest();
        $paymentMethods = self::reorderOutput($result);

        if (isset($options['country'])) {
            $paymentMethods = self::filterCountry($paymentMethods, $options['country']);
        }

        return $paymentMethods;
    }
726181
protected function makeFromArrayOfConditions( $options ) {
		$conditions = array_map( function ( $condition ) {
			if ( $condition instanceof ConditionInterface ) {
				return $condition;
			}
			return $this->make( $condition );
		}, $options );

		return new MultipleCondition( $conditions );
	}
601912
static function resolveMessageOptionsFiles(array $options) {
        if(empty($options['files'])) {
            return \React\Promise\resolve(array());
        }
        
        $promises = array();
        foreach($options['files'] as $file) {
            if($file instanceof \CharlotteDunois\Yasmin\Models\MessageAttachment) {
                $file = $file->_getMessageFilesArray();
            }
            
            if(\is_string($file)) {
                if(\filter_var($file, \FILTER_VALIDATE_URL)) {
                    $promises[] = \CharlotteDunois\Yasmin\Utils\URLHelpers::resolveURLToData($file)->then(function ($data) use ($file) {
                        return array('name' => \basename($file), 'data' => $data);
                    });
                } elseif(\realpath($file)) {
                    $promises[] = \CharlotteDunois\Yasmin\Utils\FileHelpers::resolveFileResolvable($file)->then(function ($data) use ($file) {
                        return array('name' => \basename($file), 'data' => $data);
                    });
                } else {
                    $promises[] = \React\Promise\resolve(array('name' => 'file-'.\bin2hex(\random_bytes(3)).'.jpg', 'data' => $file));
                }
                
                continue;
            }
            
            if(!\is_array($file)) {
                continue;
            }
            
            if(!isset($file['data']) && !isset($file['path'])) {
                throw new \InvalidArgumentException('Invalid file array passed, missing data and path, one is required');
            }
            
            if(!isset($file['name'])) {
                if(isset($file['path'])) {
                    $file['name'] = \basename($file['path']);
                } else {
                    $file['name'] = 'file-'.\bin2hex(\random_bytes(3)).'.jpg';
                }
            }
            
            if(isset($file['path'])) {
                if(filter_var($file['path'], \FILTER_VALIDATE_URL)) {
                    $promises[] = \CharlotteDunois\Yasmin\Utils\URLHelpers::resolveURLToData($file['path'])->then(function ($data) use ($file) {
                        $file['data'] = $data;
                        return $file;
                    });
                } elseif(\CharlotteDunois\Yasmin\Utils\FileHelpers::getFilesystem()) {
                    $promises[] = \CharlotteDunois\Yasmin\Utils\FileHelpers::getFilesystem()->getContents($file['path'])->then(function ($data) use ($file) {
                        $file['data'] = $data;
                        return $file;
                    });
                } else {
                    $file['data'] = \file_get_contents($file['path']);
                    $promises[] = \React\Promise\resolve($file);
                }
            } else {
                $promises[] = \React\Promise\resolve($file);
            }
        }
        
        return \React\Promise\all($promises);
    }
181187
public static function getInstance(array $options = array())
    {
        if (self::$instance === false) {
            $ret = new CallSpoolImpl($options);
            self::$instance = $ret;
        } else {
            $ret = self::$instance;
        }
        return self::$instance;
    }
283741
public function resources($options = [])
    {
        $url = $this->getBaseUrl();
        $resources = $this->request($url, $options);

        return $resources;
    }