note = $note; } /** * Execute the job. * * @param \GuzzleHttp\Client $guzzle */ public function handle(Client $guzzle) { //send webmention $response = $guzzle->request( 'POST', 'https://brid.gy/publish/webmention', [ 'form_params' => [ 'source' => $this->note->longurl, 'target' => 'https://brid.gy/publish/facebook', 'bridgy_omit_link' => 'maybe', ], ] ); //parse for syndication URL if ($response->getStatusCode() == 201) { $json = json_decode((string) $response->getBody()); $this->note->facebook_url = $json->url; $this->note->save(); } } }