giulioprinaricotti/laravel-gcv

Google Cloud Vision API Laravel package

dev-master 2017-10-28 14:46 UTC

This package is auto-updated.

Last update: 2022-06-29 01:26:24 UTC


README

Laravel Google Cloud Vision API package

Install

Install via Composer

composer require giulioprinaricotti/laravel-gcv

Add the following lines to your config/app.php

'providers' => [
        ...
        LaravelGCV\LaravelGCVProvider::class,
        ...
    ],


 'aliases' => [
        ...
        'LaravelGCV' => LaravelGCV\LaravelGCVFacade::class,
    ],

Example

use LaravelGCV\LaravelGCVFacade;
use Illuminate\Support\Facades\Storage;

class TestController extends Controller
{
    public function test(){
      $result = LaravelGCVFacade::colors(Storage::disk('local')->get('clc.jpg')));
    	return response()->json(compact('result'));
    }
}