src/FortniteClient.php
public static function sendUnrealClientGetRequest($endpoint, $authorization = self::EPIC_LAUNCHER_AUTHORIZATION, $oauth = false) {
        $client = new Client();

        try {
            $response = $client->get($endpoint, [
                'headers' => [
                    'User-Agent' => self::UNREAL_CLIENT_USER_AGENT,
                    'Authorization' => (!$oauth) ? 'basic ' . $authorization : 'bearer ' . $authorization
                ]
            ]);
            
            return json_decode($response->getBody()->getContents());
        } catch (GuzzleException $e) {
            throw $e; //Throw exception back up to caller
        }
    }
public static function sendUnrealClientGetRequest($endpoint, $authorization = self::EPIC_LAUNCHER_AUTHORIZATION, $oauth = false) {
        $client = new Client();

        try {
            $response = $client->get($endpoint, [
                'headers' => [
                    'User-Agent' => self::UNREAL_CLIENT_USER_AGENT,
                    'Authorization' => (!$oauth) ? 'basic ' . $authorization : 'bearer ' . $authorization
                ]
            ]);
            
            return json_decode($response->getBody()->getContents());
        } catch (GuzzleException $e) {
            throw $e; //Throw exception back up to caller
        }
    }
Sends a GET request as the Unreal Engine Client.
@param  string  $endpoint      API Endpoint to request
@param  string  $authorization Authorization header
@param  boolean $oauth         Is $authorization an OAuth2 token
@return object                 Decoded JSON response body