ml-archive / felk-php

FELK is a helper library which can take data from a Laravel request/response and push it to a store (currently ElasticSearch, hence Fuzz [ELK](https://www.elastic.co/webinars/introduction-elk-stack)).

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Felk for PHP/LaravelBuild Status Slack Status

FELK is a helper library which can take data from a Laravel request/response and push it to a store (currently ElasticSearch, hence Fuzz ELK). It is intended to only be used in development environments to debug and run analytics on API requests/responses.

Installation

$ composer require fuzz/felk-php

Configuration

  1. Add the service provider to config/app.php
    'providers' => [
        ...
        
        /*
         * Application Service Providers...
         */
        \Fuzz\Felk\Providers\FelkServiceProvider::class,
        
        ...
    ],
  2. Publish the vendor config $ php artisan vendor:publish --provider="Fuzz\Felk\Providers\FelkServiceProvider"
  3. Configure the configuration variables in config/felk.php
  4. Add the Felk middleware to the middleware stack in app/Http/Kernel.php
    /**
     * The application's global HTTP middleware stack.
     *
     * These middleware are run during every request to your application.
     *
     * @var array
     */
    protected $middleware = [
        ...
        \Fuzz\Felk\Middleware\FelkMiddleware::class,
        ...
    ];
  5. Check ElasticSearch.

About

FELK is a helper library which can take data from a Laravel request/response and push it to a store (currently ElasticSearch, hence Fuzz [ELK](https://www.elastic.co/webinars/introduction-elk-stack)).

License:MIT License


Languages

Language:PHP 100.0%