PHP code example of artisansdk / server

1. Go to this page and download the library: Download artisansdk/server library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

artisansdk / server example snippets




namespace App;

use ArtisanSDK\Server\Manager as BaseManager;

class Manager extends BaseManager
{
    public function boot()
    {
        parent::boot();

        $this->listener(...);
    }
}



return [
    'manager' => App\Manager::class,
];

php artisan vendor:publish --provider="ArtisanSDK\\Server\\Provider" --tag=config

location /server/ {
    proxy_pass http://127.0.0.1:8080;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header Host $host;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_read_timeout 5m;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "upgrade";
}