laravelgeekphp / laravel-rekognition
A simple package to enable image alt tag label detection with AWS Rekognition
Requires
- php: ^8.1
- aws/aws-sdk-php: ^3.26
- illuminate/contracts: ^9.0
- spatie/laravel-package-tools: ^1.0.0
Requires (Dev)
- laravel/pint: ^1.0
- nunomaduro/collision: ^6.3
- nunomaduro/larastan: ^2.0.1
- orchestra/testbench: ^7.0
- pestphp/pest: ^1.21
- pestphp/pest-plugin-laravel: ^1.1
- phpstan/extension-installer: ^1.1
- phpstan/phpstan-deprecation-rules: ^1.0
- phpstan/phpstan-phpunit: ^1.0
- phpunit/phpunit: ^9.5
- spatie/laravel-ray: ^1.26
- dev-main
- 0.0.7
- 0.0.6
- 0.0.5
- 0.0.4
- 0.0.3
- 0.0.2
- 0.0.1
- dev-dependabot/github_actions/stefanzweifel/git-auto-commit-action-5
- dev-dependabot/github_actions/actions/checkout-4
- dev-dependabot/github_actions/aglipanci/laravel-pint-action-2.3.0
- dev-dependabot/github_actions/ramsey/composer-install-2
- dev-1-config-files-do-not-publish
This package is auto-updated.
Last update: 2024-11-09 13:48:49 UTC
README
This is a simple open-source Laravel Package. It's only purpose is to provide a Facade for getting image labels using AWS Rekognition. Example usage is below, currently only file paths are supported. You pass the path of a file and under the hood the contents of said file is retrieved using Storage facade. The result is passed to Rekognition using HTTP client and image labels are returned.
Support us
You can support us by reading our blog
Installation
You can install the package via composer:
composer require laravelgeekphp/laravel-rekognition
You can publish the config file with:
php artisan vendor:publish --tag="rekognition-config"
This is the contents of the published config file:
return [ 'key' => env('REKOGNITION_KEY'), 'secret' => env('REKOGNITION_SECRET'), 'region' => env('AWS_DEFAULT_REGION', 'us-east-1'), ];
Usage
use \LaravelGeek\LaravelRekognition\Facades\Rekognition; use Illuminate\Support\Facades\Storage; $imageLabels = Rekognition::getFromFilePath(Storage::path($mediaPath)); // do something with your labels
Testing
composer test
Changelog
This is currently the first version ever published, there is no changelog yet.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
If you discover any security related issues, please email info@laravelgeek.com instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.