LogArc Laravel

LogArc Laravel

Latest Stable Version Total Downloads License
View Package

logarc laravel
Overview: 

LogArc Laravel allows you to integrate LogArc easily on your laravel application.


Installation: Install the package via composer:

composer require dipesh79/logarc-laravel

Add Project Key on .env

LOGARC_PROJECT_KEY="38abd738-4180-44ec-8e16-d8d24931d762"

If you don't have project key then create an account here.

Create project and you will get your project key on dashboard.

logarc dashboard
Publish the config file:

php artisan vendor:publish --provider="Dipesh79\LogArcLaravel\LogArcServiceProvider"

Usage:

<?php

namespace App\Http\Controllers;

use Dipesh79\LogArcLaravel\Facades\LogArc;
use Illuminate\Http\Client\ConnectionException;
use Illuminate\View\View;

class FrontendController extends Controller
{
    /**
     * Display the home page.
     *
     * @return View
     * @throws ConnectionException
     */
    public function home()
    {
        LogArc::emergency('This is Warning',['data'=>'demo']);
        return view('welcome');
    }
}

Available Methods:

<?php

use Dipesh79\LogArcLaravel\Facades\LogArc;

LogArc::info('info message',['data'=>'data']);
LogArc::debug('debug message',['data'=>'data']);
LogArc::error('error message',['data'=>'data']);
LogArc::notice('notice message',['data'=>'data']);
LogArc::warning('warning message',['data'=>'data']);
LogArc::critical('critical message',['data'=>'data']);
LogArc::alert('alert message',['data'=>'data']);
LogArc::emergency('emergency message',['data'=>'data']);


This post is licensed under CC BY 4.0 by the author.