93738489])->first(); //Create the ESI authentication container $config = config('esi'); $authentication = new EsiAuthentication([ 'client_id' => $config['client_id'], 'secret' => $config['secret'], 'refresh_token' => $token->refresh_token, ]); $esi = new Eseye($authentication); try { $esi->setBody([ 'approved_cost' => 0, 'body' => $body, 'recipients' => [[ 'recipient_id' => (int)$recipient, 'recipient_type' => $rType, ]], 'subject' => $subject, ])->invoke('post', '/characters/{character_id}/mail/', [ 'character_id'=> 93738489, ]); } catch(RequestFailedException $e) { return 1; } return 0; } } ?>