From a492e6bc0de0cb41db607517dfbd948664593e0c Mon Sep 17 00:00:00 2001 From: Kevin ANATOLE Date: Thu, 29 Oct 2020 07:38:36 +0000 Subject: [PATCH] Added the firebase package --- bootstrap/app.php | 6 +- composer.json | 1 + composer.lock | 1283 ++++++++++++++++++++++++++++++++++++++++++- config/firebase.php | 143 +++++ 4 files changed, 1429 insertions(+), 4 deletions(-) create mode 100644 config/firebase.php diff --git a/bootstrap/app.php b/bootstrap/app.php index b3df6ee..bfbf655 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -23,9 +23,8 @@ $app = new Laravel\Lumen\Application( dirname(__DIR__) ); -// $app->withFacades(); - -// $app->withEloquent(); +$app->withFacades(); +$app->withEloquent(); /* |-------------------------------------------------------------------------- @@ -94,6 +93,7 @@ $app->configure('app'); // $app->register(App\Providers\AppServiceProvider::class); // $app->register(App\Providers\AuthServiceProvider::class); // $app->register(App\Providers\EventServiceProvider::class); +$app->register(Kreait\Laravel\Firebase\ServiceProvider::class); /* |-------------------------------------------------------------------------- diff --git a/composer.json b/composer.json index 13ff0b4..90d9040 100644 --- a/composer.json +++ b/composer.json @@ -6,6 +6,7 @@ "type": "project", "require": { "php": "^7.2.5", + "kreait/laravel-firebase": "^2.4", "laravel/lumen-framework": "^7.0" }, "require-dev": { diff --git a/composer.lock b/composer.lock index ab3f309..81aec21 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "4be8fced66fbffeff2568a82e343bfc0", + "content-hash": "adb3f1f9c0768662ca3744917da6292a", "packages": [ { "name": "brick/math", @@ -303,6 +303,633 @@ ], "time": "2020-09-26T15:48:38+00:00" }, + { + "name": "fig/http-message-util", + "version": "1.1.4", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-message-util.git", + "reference": "3242caa9da7221a304b8f84eb9eaddae0a7cf422" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-message-util/zipball/3242caa9da7221a304b8f84eb9eaddae0a7cf422", + "reference": "3242caa9da7221a304b8f84eb9eaddae0a7cf422", + "shasum": "" + }, + "require": { + "php": "^5.3 || ^7.0" + }, + "suggest": { + "psr/http-message": "The package containing the PSR-7 interfaces" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Fig\\Http\\Message\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Utility classes and constants for use with PSR-7 (psr/http-message)", + "keywords": [ + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" + ], + "time": "2020-02-05T20:36:27+00:00" + }, + { + "name": "firebase/php-jwt", + "version": "v5.2.0", + "source": { + "type": "git", + "url": "https://github.com/firebase/php-jwt.git", + "reference": "feb0e820b8436873675fd3aca04f3728eb2185cb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/firebase/php-jwt/zipball/feb0e820b8436873675fd3aca04f3728eb2185cb", + "reference": "feb0e820b8436873675fd3aca04f3728eb2185cb", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "require-dev": { + "phpunit/phpunit": ">=4.8 <=9" + }, + "type": "library", + "autoload": { + "psr-4": { + "Firebase\\JWT\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Neuman Vong", + "email": "neuman+pear@twilio.com", + "role": "Developer" + }, + { + "name": "Anant Narayanan", + "email": "anant@php.net", + "role": "Developer" + } + ], + "description": "A simple library to encode and decode JSON Web Tokens (JWT) in PHP. Should conform to the current spec.", + "homepage": "https://github.com/firebase/php-jwt", + "keywords": [ + "jwt", + "php" + ], + "time": "2020-03-25T18:49:23+00:00" + }, + { + "name": "giggsey/libphonenumber-for-php", + "version": "8.12.11", + "source": { + "type": "git", + "url": "https://github.com/giggsey/libphonenumber-for-php.git", + "reference": "a3e8c9c832b3c40d69b477b2a96b252d03fbf274" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/giggsey/libphonenumber-for-php/zipball/a3e8c9c832b3c40d69b477b2a96b252d03fbf274", + "reference": "a3e8c9c832b3c40d69b477b2a96b252d03fbf274", + "shasum": "" + }, + "require": { + "giggsey/locale": "^1.7", + "php": ">=5.3.2", + "symfony/polyfill-mbstring": "^1.17" + }, + "require-dev": { + "pear/pear-core-minimal": "^1.9", + "pear/pear_exception": "^1.0", + "pear/versioncontrol_git": "^0.5", + "phing/phing": "^2.7", + "php-coveralls/php-coveralls": "^1.0|^2.0", + "phpunit/phpunit": "^4.8.36|^5.0", + "symfony/console": "^2.8|^3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "8.x-dev" + } + }, + "autoload": { + "psr-4": { + "libphonenumber\\": "src/" + }, + "exclude-from-classmap": [ + "/src/data/", + "/src/carrier/data/", + "/src/geocoding/data/", + "/src/timezone/data/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "Joshua Gigg", + "email": "giggsey@gmail.com", + "homepage": "https://giggsey.com/" + } + ], + "description": "PHP Port of Google's libphonenumber", + "homepage": "https://github.com/giggsey/libphonenumber-for-php", + "keywords": [ + "geocoding", + "geolocation", + "libphonenumber", + "mobile", + "phonenumber", + "validation" + ], + "time": "2020-10-09T15:01:50+00:00" + }, + { + "name": "giggsey/locale", + "version": "1.9", + "source": { + "type": "git", + "url": "https://github.com/giggsey/Locale.git", + "reference": "b07f1eace8072ccc61445ad8fbd493ff9d783043" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/giggsey/Locale/zipball/b07f1eace8072ccc61445ad8fbd493ff9d783043", + "reference": "b07f1eace8072ccc61445ad8fbd493ff9d783043", + "shasum": "" + }, + "require": { + "php": ">=5.3.2" + }, + "require-dev": { + "pear/pear-core-minimal": "^1.9", + "pear/pear_exception": "^1.0", + "pear/versioncontrol_git": "^0.5", + "phing/phing": "~2.7", + "php-coveralls/php-coveralls": "^1.0|^2.0", + "phpunit/phpunit": "^4.8|^5.0", + "symfony/console": "^2.8|^3.0|^4.0", + "symfony/filesystem": "^2.8|^3.0|^4.0", + "symfony/finder": "^2.8|^3.0|^4.0", + "symfony/process": "^2.8|^3.0|^4.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Giggsey\\Locale\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Joshua Gigg", + "email": "giggsey@gmail.com", + "homepage": "http://giggsey.com/" + } + ], + "description": "Locale functions required by libphonenumber-for-php", + "time": "2020-07-07T11:16:24+00:00" + }, + { + "name": "google/auth", + "version": "v1.14.3", + "source": { + "type": "git", + "url": "https://github.com/googleapis/google-auth-library-php.git", + "reference": "c1503299c779af0cbc99b43788f75930988852cf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/googleapis/google-auth-library-php/zipball/c1503299c779af0cbc99b43788f75930988852cf", + "reference": "c1503299c779af0cbc99b43788f75930988852cf", + "shasum": "" + }, + "require": { + "firebase/php-jwt": "~2.0|~3.0|~4.0|~5.0", + "guzzlehttp/guzzle": "^5.3.1|^6.2.1|^7.0", + "guzzlehttp/psr7": "^1.2", + "php": ">=5.4", + "psr/cache": "^1.0", + "psr/http-message": "^1.0" + }, + "require-dev": { + "guzzlehttp/promises": "0.1.1|^1.3", + "kelvinmo/simplejwt": "^0.2.5", + "phpseclib/phpseclib": "^2", + "phpunit/phpunit": "^4.8.36|^5.7", + "sebastian/comparator": ">=1.2.3", + "squizlabs/php_codesniffer": "^3.5" + }, + "suggest": { + "phpseclib/phpseclib": "May be used in place of OpenSSL for signing strings or for token management. Please require version ^2." + }, + "type": "library", + "autoload": { + "psr-4": { + "Google\\Auth\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "description": "Google Auth Library for PHP", + "homepage": "http://github.com/google/google-auth-library-php", + "keywords": [ + "Authentication", + "google", + "oauth2" + ], + "time": "2020-10-16T21:33:48+00:00" + }, + { + "name": "google/cloud-core", + "version": "v1.39.0", + "source": { + "type": "git", + "url": "https://github.com/googleapis/google-cloud-php-core.git", + "reference": "f9e7421beac89fd7d9006a13a6b39b89dd86c92e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/googleapis/google-cloud-php-core/zipball/f9e7421beac89fd7d9006a13a6b39b89dd86c92e", + "reference": "f9e7421beac89fd7d9006a13a6b39b89dd86c92e", + "shasum": "" + }, + "require": { + "google/auth": "^1.6", + "guzzlehttp/guzzle": "^5.3|^6.0|^7.0", + "guzzlehttp/promises": "^1.3", + "guzzlehttp/psr7": "^1.2", + "monolog/monolog": "^1.1|^2.0", + "php": ">=5.5", + "psr/http-message": "1.0.*", + "rize/uri-template": "~0.3" + }, + "require-dev": { + "erusev/parsedown": "^1.6", + "google/common-protos": "^1.0", + "google/gax": "^1.1", + "opis/closure": "^3", + "phpdocumentor/reflection": "^3.0", + "phpunit/phpunit": "^4.8|^5.0", + "squizlabs/php_codesniffer": "2.*" + }, + "suggest": { + "opis/closure": "May be used to serialize closures to process jobs in the batch daemon. Please require version ^3.", + "symfony/lock": "Required for the Spanner cached based session pool. Please require the following commit: 3.3.x-dev#1ba6ac9" + }, + "bin": [ + "bin/google-cloud-batch" + ], + "type": "library", + "extra": { + "component": { + "id": "cloud-core", + "target": "googleapis/google-cloud-php-core.git", + "path": "Core", + "entry": "src/ServiceBuilder.php" + } + }, + "autoload": { + "psr-4": { + "Google\\Cloud\\Core\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "description": "Google Cloud PHP shared dependency, providing functionality useful to all components.", + "time": "2020-09-08T20:52:20+00:00" + }, + { + "name": "google/cloud-storage", + "version": "v1.23.0", + "source": { + "type": "git", + "url": "https://github.com/googleapis/google-cloud-php-storage.git", + "reference": "42f7dfb248318aa152b4491b72279035df0d0900" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/googleapis/google-cloud-php-storage/zipball/42f7dfb248318aa152b4491b72279035df0d0900", + "reference": "42f7dfb248318aa152b4491b72279035df0d0900", + "shasum": "" + }, + "require": { + "google/cloud-core": "^1.39", + "google/crc32": "^0.1.0" + }, + "require-dev": { + "erusev/parsedown": "^1.6", + "google/cloud-pubsub": "^1.0", + "phpdocumentor/reflection": "^3.0", + "phpseclib/phpseclib": "^2", + "phpunit/phpunit": "^4.8|^5.0", + "squizlabs/php_codesniffer": "2.*" + }, + "suggest": { + "google/cloud-pubsub": "May be used to register a topic to receive bucket notifications.", + "phpseclib/phpseclib": "May be used in place of OpenSSL for creating signed Cloud Storage URLs. Please require version ^2." + }, + "type": "library", + "extra": { + "component": { + "id": "cloud-storage", + "target": "googleapis/google-cloud-php-storage.git", + "path": "Storage", + "entry": "src/StorageClient.php" + } + }, + "autoload": { + "psr-4": { + "Google\\Cloud\\Storage\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "description": "Cloud Storage Client for PHP", + "time": "2020-09-08T20:52:20+00:00" + }, + { + "name": "google/crc32", + "version": "v0.1.0", + "source": { + "type": "git", + "url": "https://github.com/google/php-crc32.git", + "reference": "a8525f0dea6fca1893e1bae2f6e804c5f7d007fb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/google/php-crc32/zipball/a8525f0dea6fca1893e1bae2f6e804c5f7d007fb", + "reference": "a8525f0dea6fca1893e1bae2f6e804c5f7d007fb", + "shasum": "" + }, + "require": { + "php": ">=5.4" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^1.13 || v2.14.2", + "paragonie/random_compat": ">=2", + "phpunit/phpunit": "^4" + }, + "type": "library", + "autoload": { + "psr-4": { + "Google\\CRC32\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "Andrew Brampton", + "email": "bramp@google.com" + } + ], + "description": "Various CRC32 implementations", + "homepage": "https://github.com/google/php-crc32", + "time": "2019-05-09T06:24:58+00:00" + }, + { + "name": "guzzlehttp/guzzle", + "version": "7.2.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/guzzle.git", + "reference": "0aa74dfb41ae110835923ef10a9d803a22d50e79" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/0aa74dfb41ae110835923ef10a9d803a22d50e79", + "reference": "0aa74dfb41ae110835923ef10a9d803a22d50e79", + "shasum": "" + }, + "require": { + "ext-json": "*", + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" + }, + "require-dev": { + "ext-curl": "*", + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.5 || ^9.3.5", + "psr/log": "^1.1" + }, + "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", + "psr/log": "Required for using the Log middleware" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "7.1-dev" + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\": "src/" + }, + "files": [ + "src/functions_include.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" + } + ], + "description": "Guzzle is a PHP HTTP client library", + "homepage": "http://guzzlephp.org/", + "keywords": [ + "client", + "curl", + "framework", + "http", + "http client", + "psr-18", + "psr-7", + "rest", + "web service" + ], + "time": "2020-10-10T11:47:56+00:00" + }, + { + "name": "guzzlehttp/promises", + "version": "1.4.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/promises.git", + "reference": "60d379c243457e073cff02bc323a2a86cb355631" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/promises/zipball/60d379c243457e073cff02bc323a2a86cb355631", + "reference": "60d379c243457e073cff02bc323a2a86cb355631", + "shasum": "" + }, + "require": { + "php": ">=5.5" + }, + "require-dev": { + "symfony/phpunit-bridge": "^4.4 || ^5.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.4-dev" + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Promise\\": "src/" + }, + "files": [ + "src/functions_include.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + } + ], + "description": "Guzzle promises library", + "keywords": [ + "promise" + ], + "time": "2020-09-30T07:37:28+00:00" + }, + { + "name": "guzzlehttp/psr7", + "version": "1.7.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/psr7.git", + "reference": "53330f47520498c0ae1f61f7e2c90f55690c06a3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/53330f47520498c0ae1f61f7e2c90f55690c06a3", + "reference": "53330f47520498c0ae1f61f7e2c90f55690c06a3", + "shasum": "" + }, + "require": { + "php": ">=5.4.0", + "psr/http-message": "~1.0", + "ralouphie/getallheaders": "^2.0.5 || ^3.0.0" + }, + "provide": { + "psr/http-message-implementation": "1.0" + }, + "require-dev": { + "ext-zlib": "*", + "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.10" + }, + "suggest": { + "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.7-dev" + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Psr7\\": "src/" + }, + "files": [ + "src/functions_include.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Tobias Schultze", + "homepage": "https://github.com/Tobion" + } + ], + "description": "PSR-7 message implementation that also provides common utility methods", + "keywords": [ + "http", + "message", + "psr-7", + "request", + "response", + "stream", + "uri", + "url" + ], + "time": "2020-09-30T07:37:11+00:00" + }, { "name": "illuminate/auth", "version": "v7.28.4", @@ -1504,6 +2131,267 @@ "homepage": "https://laravel.com", "time": "2020-09-14T13:24:58+00:00" }, + { + "name": "kreait/clock", + "version": "1.1.0", + "source": { + "type": "git", + "url": "https://github.com/kreait/clock-php.git", + "reference": "8f1fbc252e4e81298ae7c520597c25e9a6a0f454" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/kreait/clock-php/zipball/8f1fbc252e4e81298ae7c520597c25e9a6a0f454", + "reference": "8f1fbc252e4e81298ae7c520597c25e9a6a0f454", + "shasum": "" + }, + "require": { + "php": "^7.0|^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^6.5.14" + }, + "type": "library", + "autoload": { + "psr-4": { + "Kreait\\Clock\\": "src/Clock" + }, + "files": [ + "src/Clock.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jérôme Gamez", + "email": "jerome@gamez.name" + } + ], + "description": "A PHP 7.0 compatible clock abstraction", + "time": "2020-10-03T23:30:50+00:00" + }, + { + "name": "kreait/firebase-php", + "version": "5.10.0", + "source": { + "type": "git", + "url": "https://github.com/kreait/firebase-php.git", + "reference": "9c85fe5e26c88cfd406ac08f671d4cd99595f1d0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/kreait/firebase-php/zipball/9c85fe5e26c88cfd406ac08f671d4cd99595f1d0", + "reference": "9c85fe5e26c88cfd406ac08f671d4cd99595f1d0", + "shasum": "" + }, + "require": { + "ext-ctype": "*", + "ext-json": "*", + "ext-mbstring": "*", + "ext-openssl": "*", + "giggsey/libphonenumber-for-php": "^8.9", + "google/auth": "^1.8", + "google/cloud-core": "^1.36", + "google/cloud-storage": "^1.14", + "guzzlehttp/guzzle": "^6.2.1|^7.0", + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7", + "kreait/clock": "^1.0.1", + "kreait/firebase-tokens": "^1.10", + "lcobucci/jwt": "^3.3.1", + "mtdowling/jmespath.php": "^2.3", + "php": "^7.2|^8.0", + "psr/cache": "^1.0", + "psr/http-message": "^1.0", + "psr/log": "^1.1", + "psr/simple-cache": "^1.0", + "riverline/multipart-parser": "^2.0" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "^2.16", + "google/cloud-firestore": "^1.11", + "jangregor/phpstan-prophecy": "^0.6.2", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^0.12.15", + "phpstan/phpstan-phpunit": "^0.12.6", + "phpunit/phpunit": "^8.5", + "symfony/var-dumper": "^5.0" + }, + "suggest": { + "google/cloud-firestore": "^1.0 to use the Firestore component" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "5.x-dev", + "dev-4.x": "4.x-dev" + } + }, + "autoload": { + "psr-4": { + "Kreait\\Firebase\\": "src/Firebase" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jérôme Gamez", + "homepage": "https://github.com/jeromegamez" + } + ], + "description": "Firebase Admin SDK", + "homepage": "https://github.com/kreait/firebase-php", + "keywords": [ + "api", + "database", + "firebase", + "google", + "sdk" + ], + "time": "2020-10-20T18:41:52+00:00" + }, + { + "name": "kreait/firebase-tokens", + "version": "1.11.0", + "source": { + "type": "git", + "url": "https://github.com/kreait/firebase-tokens-php.git", + "reference": "26dcb56cb49cea30fd020a416f53f59d2d78a58b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/kreait/firebase-tokens-php/zipball/26dcb56cb49cea30fd020a416f53f59d2d78a58b", + "reference": "26dcb56cb49cea30fd020a416f53f59d2d78a58b", + "shasum": "" + }, + "require": { + "ext-json": "*", + "ext-openssl": "*", + "fig/http-message-util": "^1.1", + "guzzlehttp/guzzle": "^6.2.1|^7.0", + "kreait/clock": "^1.0.1", + "lcobucci/jwt": "^3.2", + "php": "^7.0|^8.0", + "psr/cache": "^1.0", + "psr/simple-cache": "^1.0" + }, + "require-dev": { + "firebase/php-jwt": "^5.0", + "friendsofphp/php-cs-fixer": "^2.16", + "phpstan/phpstan-phpunit": "^0.9.4|^0.11.2", + "phpunit/phpunit": "^6.5.14|^7.5.17", + "symfony/cache": "^3.4.26|^4.4|^5.0", + "symfony/var-dumper": "^3.4|^4.4|^5.0" + }, + "suggest": { + "firebase/php-jwt": "^5.0 can be used to create and parse tokens", + "guzzlehttp/guzzle": "^6.2.1|^7.0 can be used as an HTTP handler", + "lcobucci/jwt": "^3.2 can be used to create and parse tokens", + "psr/cache-implementation": "to cache fetched remote public keys", + "psr/simple-cache-implementation": "to cache fetched remote public keys" + }, + "type": "library", + "autoload": { + "psr-4": { + "Kreait\\Firebase\\JWT\\": "src/JWT", + "Firebase\\Auth\\Token\\": "src/Firebase/Auth/Token" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jérôme Gamez", + "homepage": "https://github.com/jeromegamez" + } + ], + "description": "A library to work with Firebase tokens", + "homepage": "https://github.com/kreait/firebase-token-php", + "keywords": [ + "Authentication", + "auth", + "firebase", + "google", + "token" + ], + "time": "2020-10-04T00:32:51+00:00" + }, + { + "name": "kreait/laravel-firebase", + "version": "2.4.0", + "source": { + "type": "git", + "url": "https://github.com/kreait/laravel-firebase.git", + "reference": "6ceb50b05c934e56e12bd70ad9c2a221f54cc4f8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/kreait/laravel-firebase/zipball/6ceb50b05c934e56e12bd70ad9c2a221f54cc4f8", + "reference": "6ceb50b05c934e56e12bd70ad9c2a221f54cc4f8", + "shasum": "" + }, + "require": { + "illuminate/contracts": "^5.8|^6.0|^7.0|^8.0", + "illuminate/support": "^5.8|^6.0|^7.0|^8.0", + "kreait/firebase-php": "^5.8.1", + "php": "^7.2|^8.0" + }, + "require-dev": { + "orchestra/testbench": "^3.8.6|^4.8|^5.2|^6.0", + "roave/better-reflection": "^3.6|^4.6" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + }, + "laravel": { + "providers": [ + "Kreait\\Laravel\\Firebase\\ServiceProvider" + ], + "aliases": { + "FirebaseAuth": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseAuth", + "FirebaseDatabase": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseDatabase", + "FirebaseDynamicLinks": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseDynamicLinks", + "FirebaseFirestore": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseFirestore", + "FirebaseMessaging": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseMessaging", + "FirebaseRemoteConfig": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseRemoteConfig", + "FirebaseStorage": "Kreait\\Laravel\\Firebase\\Facades\\FirebaseStorage" + } + } + }, + "autoload": { + "psr-4": { + "Kreait\\Laravel\\Firebase\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jérôme Gamez", + "email": "jerome@gamez.name" + } + ], + "description": "A Laravel package for the Firebase PHP Admin SDK", + "keywords": [ + "FCM", + "firebase", + "gcm", + "laravel" + ], + "time": "2020-10-04T12:17:51+00:00" + }, { "name": "laravel/lumen-framework", "version": "v7.2.2", @@ -1595,6 +2483,61 @@ ], "time": "2020-09-15T14:53:08+00:00" }, + { + "name": "lcobucci/jwt", + "version": "3.3.3", + "source": { + "type": "git", + "url": "https://github.com/lcobucci/jwt.git", + "reference": "c1123697f6a2ec29162b82f170dd4a491f524773" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/lcobucci/jwt/zipball/c1123697f6a2ec29162b82f170dd4a491f524773", + "reference": "c1123697f6a2ec29162b82f170dd4a491f524773", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "ext-openssl": "*", + "php": "^5.6 || ^7.0" + }, + "require-dev": { + "mikey179/vfsstream": "~1.5", + "phpmd/phpmd": "~2.2", + "phpunit/php-invoker": "~1.1", + "phpunit/phpunit": "^5.7 || ^7.3", + "squizlabs/php_codesniffer": "~2.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "autoload": { + "psr-4": { + "Lcobucci\\JWT\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Luís Otávio Cobucci Oblonczyk", + "email": "lcobucci@gmail.com", + "role": "Developer" + } + ], + "description": "A simple library to work with JSON Web Token and JSON Web Signature", + "keywords": [ + "JWS", + "jwt" + ], + "time": "2020-08-20T13:22:28+00:00" + }, { "name": "monolog/monolog", "version": "2.1.1", @@ -1676,6 +2619,63 @@ ], "time": "2020-07-23T08:41:23+00:00" }, + { + "name": "mtdowling/jmespath.php", + "version": "2.6.0", + "source": { + "type": "git", + "url": "https://github.com/jmespath/jmespath.php.git", + "reference": "42dae2cbd13154083ca6d70099692fef8ca84bfb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jmespath/jmespath.php/zipball/42dae2cbd13154083ca6d70099692fef8ca84bfb", + "reference": "42dae2cbd13154083ca6d70099692fef8ca84bfb", + "shasum": "" + }, + "require": { + "php": "^5.4 || ^7.0 || ^8.0", + "symfony/polyfill-mbstring": "^1.17" + }, + "require-dev": { + "composer/xdebug-handler": "^1.4", + "phpunit/phpunit": "^4.8.36 || ^7.5.15" + }, + "bin": [ + "bin/jp.php" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.6-dev" + } + }, + "autoload": { + "psr-4": { + "JmesPath\\": "src/" + }, + "files": [ + "src/JmesPath.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + } + ], + "description": "Declaratively specify how to extract elements from a JSON document", + "keywords": [ + "json", + "jsonpath" + ], + "time": "2020-07-31T21:01:56+00:00" + }, { "name": "nesbot/carbon", "version": "2.41.5", @@ -1917,6 +2917,52 @@ ], "time": "2020-07-20T17:29:33+00:00" }, + { + "name": "psr/cache", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/cache.git", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/cache/zipball/d11b50ad223250cf17b86e38383413f5a6764bf8", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Cache\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for caching libraries", + "keywords": [ + "cache", + "psr", + "psr-6" + ], + "time": "2016-08-06T20:24:11+00:00" + }, { "name": "psr/container", "version": "1.0.0", @@ -2012,6 +3058,105 @@ ], "time": "2019-01-08T18:20:26+00:00" }, + { + "name": "psr/http-client", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", + "keywords": [ + "http", + "http-client", + "psr", + "psr-18" + ], + "time": "2020-06-29T06:28:15+00:00" + }, + { + "name": "psr/http-message", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-message.git", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Http\\Message\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for HTTP messages", + "homepage": "https://github.com/php-fig/http-message", + "keywords": [ + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" + ], + "time": "2016-08-06T14:39:51+00:00" + }, { "name": "psr/log", "version": "1.1.3", @@ -2107,6 +3252,46 @@ ], "time": "2017-10-23T01:57:42+00:00" }, + { + "name": "ralouphie/getallheaders", + "version": "3.0.3", + "source": { + "type": "git", + "url": "https://github.com/ralouphie/getallheaders.git", + "reference": "120b605dfeb996808c31b6477290a714d356e822" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", + "shasum": "" + }, + "require": { + "php": ">=5.6" + }, + "require-dev": { + "php-coveralls/php-coveralls": "^2.1", + "phpunit/phpunit": "^5 || ^6.5" + }, + "type": "library", + "autoload": { + "files": [ + "src/getallheaders.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" + } + ], + "description": "A polyfill for getallheaders.", + "time": "2019-03-08T08:55:37+00:00" + }, { "name": "ramsey/collection", "version": "1.1.1", @@ -2251,6 +3436,102 @@ ], "time": "2020-08-18T17:17:46+00:00" }, + { + "name": "riverline/multipart-parser", + "version": "2.0.8", + "source": { + "type": "git", + "url": "https://github.com/Riverline/multipart-parser.git", + "reference": "2fe9026789754c1ff07c06047f0acc113e90933a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Riverline/multipart-parser/zipball/2fe9026789754c1ff07c06047f0acc113e90933a", + "reference": "2fe9026789754c1ff07c06047f0acc113e90933a", + "shasum": "" + }, + "require": { + "ext-mbstring": "*", + "php": ">=5.6.0" + }, + "require-dev": { + "laminas/laminas-diactoros": "^1.8.7", + "phpunit/phpunit": "^5.2 || ^6.0 || ^7.0", + "psr/http-message": "^1.0", + "symfony/psr-http-message-bridge": "^1.1" + }, + "type": "library", + "autoload": { + "psr-4": { + "Riverline\\MultiPartParser\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Romain Cambien", + "email": "romain@cambien.net" + }, + { + "name": "Riverline", + "homepage": "http://www.riverline.fr" + } + ], + "description": "One class library to parse multipart content with encoding and charset support.", + "keywords": [ + "http", + "multipart", + "parser" + ], + "time": "2020-01-24T09:39:24+00:00" + }, + { + "name": "rize/uri-template", + "version": "0.3.2", + "source": { + "type": "git", + "url": "https://github.com/rize/UriTemplate.git", + "reference": "9e5fdd5c47147aa5adf7f760002ee591ed37b9ca" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/rize/UriTemplate/zipball/9e5fdd5c47147aa5adf7f760002ee591ed37b9ca", + "reference": "9e5fdd5c47147aa5adf7f760002ee591ed37b9ca", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "require-dev": { + "phpunit/phpunit": "~4.0.0" + }, + "type": "library", + "autoload": { + "psr-0": { + "Rize\\UriTemplate": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Marut K", + "homepage": "http://twitter.com/rezigned" + } + ], + "description": "PHP URI Template (RFC 6570) supports both expansion & extraction", + "keywords": [ + "RFC 6570", + "template", + "uri" + ], + "time": "2017-06-14T03:57:53+00:00" + }, { "name": "symfony/console", "version": "v5.1.8", diff --git a/config/firebase.php b/config/firebase.php new file mode 100644 index 0000000..14e55ac --- /dev/null +++ b/config/firebase.php @@ -0,0 +1,143 @@ + [ + 'file' => env('FIREBASE_CREDENTIALS'), + + /** + * If you want to prevent the auto discovery of credentials, set the + * following parameter to false. If you disable it, you must + * provide a credentials file. + */ + 'auto_discovery' => true, + ], + + /** + * ------------------------------------------------------------------------ + * Firebase Realtime Database + * ------------------------------------------------------------------------ + */ + + 'database' => [ + + /** + * In most of the cases the project ID defined in the credentials file + * determines the URL of your project's Realtime Database. If the + * connection to the Realtime Database fails, you can override + * its URL with the value you see at + * + * https://console.firebase.google.com/u/1/project/_/database + * + * Please make sure that you use a full URL like, for example, + * https://my-project-id.firebaseio.com + */ + 'url' => env('FIREBASE_DATABASE_URL'), + + ], + + 'dynamic_links' => [ + + /** + * Dynamic links can be built with any URL prefix registered on + * + * https://console.firebase.google.com/u/1/project/_/durablelinks/links/ + * + * You can define one of those domains as the default for new Dynamic + * Links created within your project. + * + * The value must be a valid domain, for example, + * https://example.page.link + */ + 'default_domain' => env('FIREBASE_DYNAMIC_LINKS_DEFAULT_DOMAIN') + ], + + /** + * ------------------------------------------------------------------------ + * Firebase Cloud Storage + * ------------------------------------------------------------------------ + */ + + 'storage' => [ + + /** + * Your project's default storage bucket usually uses the project ID + * as its name. If you have multiple storage buckets and want to + * use another one as the default for your application, you can + * override it here. + */ + + 'default_bucket' => env('FIREBASE_STORAGE_DEFAULT_BUCKET'), + + ], + + /** + * ------------------------------------------------------------------------ + * Caching + * ------------------------------------------------------------------------ + * + * The Firebase Admin SDK can cache some data returned from the Firebase + * API, for example Google's public keys used to verify ID tokens. + * + */ + + 'cache_store' => env('FIREBASE_CACHE_STORE', 'file'), + + /** + * ------------------------------------------------------------------------ + * Logging + * ------------------------------------------------------------------------ + * + * Enable logging of HTTP interaction for insights and/or debugging. + * + * Log channels are defined in config/logging.php + * + * Successful HTTP messages are logged with the log level 'info'. + * Failed HTTP messages are logged with the the log level 'notice'. + * + * Note: Using the same channel for simple and debug logs will result in + * two entries per request and response. + */ + + 'logging' => [ + 'http_log_channel' => env('FIREBASE_HTTP_LOG_CHANNEL', null), + 'http_debug_log_channel' => env('FIREBASE_HTTP_DEBUG_LOG_CHANNEL', null), + ], + + /** + * ------------------------------------------------------------------------ + * Debug (deprecated) + * ------------------------------------------------------------------------ + * + * Enable debugging of HTTP requests made directly from the SDK. + */ + 'debug' => env('FIREBASE_ENABLE_DEBUG', false), +];