onQueue('high'); } /** * Execute the job. */ public function handle(): void { $response = $this->sendNotificationRequest('Pushover', 'https://api.pushover.net/1/messages.json', fn () => Http::post('https://api.pushover.net/1/messages.json', $this->message->toPayload($this->token, $this->user))); // Pushover marks the invalid field in the error body, for example {"token": "invalid"}. $isConfigurationError = $response->clientError() && ($response->json('token') === 'invalid' || $response->json('user') === 'invalid'); $this->handleNotificationResponse($response, 'Pushover', $isConfigurationError); } }