'application/activity+json, application/ld+json', ]; $headers = HttpSignature::instanceActorSign($url, false, $baseHeaders, 'get'); $headers['Accept'] = 'application/activity+json, application/ld+json'; $headers['User-Agent'] = 'PixelFedBot/1.0.0 (Pixelfed/'.config('pixelfed.version').'; +'.config('app.url').')'; try { $res = Http::withOptions(['allow_redirects' => false])->withHeaders($headers) ->timeout(30) ->connectTimeout(5) ->retry(3, 500) ->get($url); } catch (RequestException $e) { return; } catch (ConnectionException $e) { return; } catch (Exception $e) { return; } if(!$res->ok()) { return; } return $res->body(); } }