diff --git a/.gitignore b/.gitignore index 506a553..fc8b8c4 100644 --- a/.gitignore +++ b/.gitignore @@ -7,4 +7,5 @@ public_key.pem .DS_Store box.config.php phpunit.xml -composer.lock \ No newline at end of file +composer.lock +.phpunit.result.cache diff --git a/README.md b/README.md index aad7905..a536de4 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,12 @@ ## Getting Started -Before you can begin working on your PHP code, you'll need to configure your application settings with Box. To start your application configuration, follow these [instructions](https://developer.box.com/v2.0/docs/configuring-box-platform). +Before you can begin working on your PHP code, you'll need to configure your application settings with Box. To start your application configuration, follow these [instructions](https://developer.box.com/guides/authentication/jwt/jwt-setup/). Make sure to select **OAuth 2.0 with JWT (Server Authentication)** for **Authentication Method**. +For "App Access Level" select "App + Enterprise Access". + Also make sure to give your application the permissions to handle files and folders. For the purpose of the included examples, permission should be given to read and write files and perform actions as users. After you've created/generated your RSA keypair, download your app configuration JSON file. @@ -31,6 +33,11 @@ return array( Install dependencies (assuming you already have [Composer](https://getcomposer.org/) installed). +NOTE: You need Composer 2.2 LTS installed. During composer install run: +```bash +php composer-setup.php --2.2 +``` + ```bash composer install ``` diff --git a/composer.json b/composer.json index 668a23a..fbda3fc 100644 --- a/composer.json +++ b/composer.json @@ -1,10 +1,10 @@ { "name": "amsxbg/box-jwt", "require": { - "guzzlehttp/guzzle": "^7.2", - "firebase/php-jwt": "^5.2", - "laminas/laminas-config": "^3.4", - "laminas/laminas-dependency-plugin": "^2.1" + "guzzlehttp/guzzle": "^7.4", + "firebase/php-jwt": "^6.0", + "laminas/laminas-config": "^3.9", + "laminas/laminas-dependency-plugin": "^2.5" }, "require-dev": { "phpunit/phpunit": "^9.3" @@ -21,5 +21,10 @@ "classmap": [ "tests/TestCase.php" ] + }, + "config": { + "allow-plugins": { + "laminas/laminas-dependency-plugin": true + } } } diff --git a/composer.lock b/composer.lock index d18e8fc..8ff5e1b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,29 +4,35 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "52aecd237631c1850ba6e878fd52710c", + "content-hash": "9eaa8163213118486b9f284ee216a0f5", "packages": [ { "name": "firebase/php-jwt", - "version": "v5.5.0", + "version": "v6.8.1", "source": { "type": "git", "url": "https://github.com/firebase/php-jwt.git", - "reference": "cf814442ce0e9eebe5317d61b63ccda4b85de67a" + "reference": "5dbc8959427416b8ee09a100d7a8588c00fb2e26" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/firebase/php-jwt/zipball/cf814442ce0e9eebe5317d61b63ccda4b85de67a", - "reference": "cf814442ce0e9eebe5317d61b63ccda4b85de67a", + "url": "https://api.github.com/repos/firebase/php-jwt/zipball/5dbc8959427416b8ee09a100d7a8588c00fb2e26", + "reference": "5dbc8959427416b8ee09a100d7a8588c00fb2e26", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "^7.4||^8.0" }, "require-dev": { - "phpunit/phpunit": ">=4.8 <=9" + "guzzlehttp/guzzle": "^6.5||^7.4", + "phpspec/prophecy-phpunit": "^2.0", + "phpunit/phpunit": "^9.5", + "psr/cache": "^1.0||^2.0", + "psr/http-client": "^1.0", + "psr/http-factory": "^1.0" }, "suggest": { + "ext-sodium": "Support EdDSA (Ed25519) signatures", "paragonie/sodium_compat": "Support EdDSA (Ed25519) signatures when libsodium is not present" }, "type": "library", @@ -59,40 +65,41 @@ ], "support": { "issues": "https://github.com/firebase/php-jwt/issues", - "source": "https://github.com/firebase/php-jwt/tree/v5.5.0" + "source": "https://github.com/firebase/php-jwt/tree/v6.8.1" }, - "time": "2021-11-04T16:21:41+00:00" + "time": "2023-07-14T18:33:00+00:00" }, { "name": "guzzlehttp/guzzle", - "version": "7.4.0", + "version": "7.8.0", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "868b3571a039f0ebc11ac8f344f4080babe2cb94" + "reference": "1110f66a6530a40fe7aea0378fe608ee2b2248f9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/868b3571a039f0ebc11ac8f344f4080babe2cb94", - "reference": "868b3571a039f0ebc11ac8f344f4080babe2cb94", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/1110f66a6530a40fe7aea0378fe608ee2b2248f9", + "reference": "1110f66a6530a40fe7aea0378fe608ee2b2248f9", "shasum": "" }, "require": { "ext-json": "*", - "guzzlehttp/promises": "^1.5", - "guzzlehttp/psr7": "^1.8.3 || ^2.1", + "guzzlehttp/promises": "^1.5.3 || ^2.0.1", + "guzzlehttp/psr7": "^1.9.1 || ^2.5.1", "php": "^7.2.5 || ^8.0", "psr/http-client": "^1.0", - "symfony/deprecation-contracts": "^2.2" + "symfony/deprecation-contracts": "^2.2 || ^3.0" }, "provide": { "psr/http-client-implementation": "1.0" }, "require-dev": { - "bamarni/composer-bin-plugin": "^1.4.1", + "bamarni/composer-bin-plugin": "^1.8.1", "ext-curl": "*", - "php-http/client-integration-tests": "^3.0", - "phpunit/phpunit": "^8.5.5 || ^9.3.5", + "php-http/client-integration-tests": "dev-master#2c025848417c1135031fdf9c728ee53d0a7ceaee as 3.0.999", + "php-http/message-factory": "^1.1", + "phpunit/phpunit": "^8.5.29 || ^9.5.23", "psr/log": "^1.1 || ^2.0 || ^3.0" }, "suggest": { @@ -102,17 +109,18 @@ }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "7.4-dev" + "bamarni-bin": { + "bin-links": true, + "forward-command": false } }, "autoload": { - "psr-4": { - "GuzzleHttp\\": "src/" - }, "files": [ "src/functions_include.php" - ] + ], + "psr-4": { + "GuzzleHttp\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -169,7 +177,7 @@ ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/7.4.0" + "source": "https://github.com/guzzle/guzzle/tree/7.8.0" }, "funding": [ { @@ -185,41 +193,40 @@ "type": "tidelift" } ], - "time": "2021-10-18T09:52:00+00:00" + "time": "2023-08-27T10:20:53+00:00" }, { "name": "guzzlehttp/promises", - "version": "1.5.1", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/guzzle/promises.git", - "reference": "fe752aedc9fd8fcca3fe7ad05d419d32998a06da" + "reference": "111166291a0f8130081195ac4556a5587d7f1b5d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/promises/zipball/fe752aedc9fd8fcca3fe7ad05d419d32998a06da", - "reference": "fe752aedc9fd8fcca3fe7ad05d419d32998a06da", + "url": "https://api.github.com/repos/guzzle/promises/zipball/111166291a0f8130081195ac4556a5587d7f1b5d", + "reference": "111166291a0f8130081195ac4556a5587d7f1b5d", "shasum": "" }, "require": { - "php": ">=5.5" + "php": "^7.2.5 || ^8.0" }, "require-dev": { - "symfony/phpunit-bridge": "^4.4 || ^5.1" + "bamarni/composer-bin-plugin": "^1.8.1", + "phpunit/phpunit": "^8.5.29 || ^9.5.23" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.5-dev" + "bamarni-bin": { + "bin-links": true, + "forward-command": false } }, "autoload": { "psr-4": { "GuzzleHttp\\Promise\\": "src/" - }, - "files": [ - "src/functions_include.php" - ] + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -253,7 +260,7 @@ ], "support": { "issues": "https://github.com/guzzle/promises/issues", - "source": "https://github.com/guzzle/promises/tree/1.5.1" + "source": "https://github.com/guzzle/promises/tree/2.0.1" }, "funding": [ { @@ -269,26 +276,26 @@ "type": "tidelift" } ], - "time": "2021-10-22T20:56:57+00:00" + "time": "2023-08-03T15:11:55+00:00" }, { "name": "guzzlehttp/psr7", - "version": "2.1.0", + "version": "2.6.1", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "089edd38f5b8abba6cb01567c2a8aaa47cec4c72" + "reference": "be45764272e8873c72dbe3d2edcfdfcc3bc9f727" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/089edd38f5b8abba6cb01567c2a8aaa47cec4c72", - "reference": "089edd38f5b8abba6cb01567c2a8aaa47cec4c72", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/be45764272e8873c72dbe3d2edcfdfcc3bc9f727", + "reference": "be45764272e8873c72dbe3d2edcfdfcc3bc9f727", "shasum": "" }, "require": { "php": "^7.2.5 || ^8.0", "psr/http-factory": "^1.0", - "psr/http-message": "^1.0", + "psr/http-message": "^1.1 || ^2.0", "ralouphie/getallheaders": "^3.0" }, "provide": { @@ -296,17 +303,18 @@ "psr/http-message-implementation": "1.0" }, "require-dev": { - "bamarni/composer-bin-plugin": "^1.4.1", + "bamarni/composer-bin-plugin": "^1.8.1", "http-interop/http-factory-tests": "^0.9", - "phpunit/phpunit": "^8.5.8 || ^9.3.10" + "phpunit/phpunit": "^8.5.29 || ^9.5.23" }, "suggest": { "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "2.1-dev" + "bamarni-bin": { + "bin-links": true, + "forward-command": false } }, "autoload": { @@ -368,7 +376,7 @@ ], "support": { "issues": "https://github.com/guzzle/psr7/issues", - "source": "https://github.com/guzzle/psr7/tree/2.1.0" + "source": "https://github.com/guzzle/psr7/tree/2.6.1" }, "funding": [ { @@ -384,26 +392,26 @@ "type": "tidelift" } ], - "time": "2021-10-06T17:43:30+00:00" + "time": "2023-08-27T10:13:57+00:00" }, { "name": "laminas/laminas-config", - "version": "3.7.0", + "version": "3.9.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-config.git", - "reference": "e43d13dcfc273d4392812eb395ce636f73f34dfd" + "reference": "e53717277f6c22b1c697a46473b9a5ec9a438efa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-config/zipball/e43d13dcfc273d4392812eb395ce636f73f34dfd", - "reference": "e43d13dcfc273d4392812eb395ce636f73f34dfd", + "url": "https://api.github.com/repos/laminas/laminas-config/zipball/e53717277f6c22b1c697a46473b9a5ec9a438efa", + "reference": "e53717277f6c22b1c697a46473b9a5ec9a438efa", "shasum": "" }, "require": { "ext-json": "*", "laminas/laminas-stdlib": "^3.6", - "php": "^7.3 || ~8.0.0 || ~8.1.0", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0", "psr/container": "^1.0" }, "conflict": { @@ -411,11 +419,11 @@ "zendframework/zend-config": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-filter": "^2.7.2", - "laminas/laminas-i18n": "^2.10.3", - "laminas/laminas-servicemanager": "^3.7", - "phpunit/phpunit": "^9.5.5" + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-filter": "~2.23.0", + "laminas/laminas-i18n": "~2.19.0", + "laminas/laminas-servicemanager": "~3.19.0", + "phpunit/phpunit": "~9.5.25" }, "suggest": { "laminas/laminas-filter": "^2.7.2; install if you want to use the Filter processor", @@ -452,32 +460,32 @@ "type": "community_bridge" } ], - "time": "2021-10-01T16:07:46+00:00" + "time": "2023-09-19T12:02:54+00:00" }, { "name": "laminas/laminas-dependency-plugin", - "version": "2.2.0", + "version": "2.5.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-dependency-plugin.git", - "reference": "73cfb63ddca9d6bfedad5e0a038f6d55063975a3" + "reference": "8f2d10199381cdc7d0843bfadad55f8485df9e38" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-dependency-plugin/zipball/73cfb63ddca9d6bfedad5e0a038f6d55063975a3", - "reference": "73cfb63ddca9d6bfedad5e0a038f6d55063975a3", + "url": "https://api.github.com/repos/laminas/laminas-dependency-plugin/zipball/8f2d10199381cdc7d0843bfadad55f8485df9e38", + "reference": "8f2d10199381cdc7d0843bfadad55f8485df9e38", "shasum": "" }, "require": { - "composer-plugin-api": "^1.1 || ^2.0", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "composer-plugin-api": ">=1.1.0 <2.3.0", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "require-dev": { - "composer/composer": "^1.9 || ^2.0", - "laminas/laminas-coding-standard": "^2.2.1", - "mikey179/vfsstream": "^1.6.10@alpha", + "composer/composer": ">=1.9.0 <2.3.0", + "laminas/laminas-coding-standard": "~2.4.0", + "mikey179/vfsstream": "^1.6.11", "phpunit/phpunit": "^9.5.5", - "psalm/plugin-phpunit": "^0.15.1", + "psalm/plugin-phpunit": "^0.17.0", "roave/security-advisories": "dev-master", "vimeo/psalm": "^4.5" }, @@ -497,7 +505,7 @@ "description": "Replace zendframework and zfcampus packages with their Laminas Project equivalents.", "support": { "issues": "https://github.com/laminas/laminas-dependency-plugin/issues", - "source": "https://github.com/laminas/laminas-dependency-plugin/tree/2.2.0" + "source": "https://github.com/laminas/laminas-dependency-plugin/tree/2.5.0" }, "funding": [ { @@ -505,34 +513,34 @@ "type": "community_bridge" } ], - "time": "2021-09-08T17:51:35+00:00" + "time": "2022-10-16T14:45:47+00:00" }, { "name": "laminas/laminas-stdlib", - "version": "3.6.0", + "version": "3.18.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "c53d8537f108fac3fae652677a19735db730ba46" + "reference": "e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/c53d8537f108fac3fae652677a19735db730ba46", - "reference": "c53d8537f108fac3fae652677a19735db730ba46", + "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf", + "reference": "e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf", "shasum": "" }, "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-stdlib": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.3.0", - "phpbench/phpbench": "^0.17.1", - "phpunit/phpunit": "~9.3.7", - "psalm/plugin-phpunit": "^0.16.0", - "vimeo/psalm": "^4.7" + "laminas/laminas-coding-standard": "^2.5", + "phpbench/phpbench": "^1.2.14", + "phpunit/phpunit": "^10.3.3", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.15.0" }, "type": "library", "autoload": { @@ -564,24 +572,24 @@ "type": "community_bridge" } ], - "time": "2021-09-02T16:11:32+00:00" + "time": "2023-09-19T10:15:21+00:00" }, { "name": "psr/container", - "version": "1.1.1", + "version": "1.1.2", "source": { "type": "git", "url": "https://github.com/php-fig/container.git", - "reference": "8622567409010282b7aeebe4bb841fe98b58dcaf" + "reference": "513e0666f7216c7459170d56df27dfcefe1689ea" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/8622567409010282b7aeebe4bb841fe98b58dcaf", - "reference": "8622567409010282b7aeebe4bb841fe98b58dcaf", + "url": "https://api.github.com/repos/php-fig/container/zipball/513e0666f7216c7459170d56df27dfcefe1689ea", + "reference": "513e0666f7216c7459170d56df27dfcefe1689ea", "shasum": "" }, "require": { - "php": ">=7.2.0" + "php": ">=7.4.0" }, "type": "library", "autoload": { @@ -610,27 +618,27 @@ ], "support": { "issues": "https://github.com/php-fig/container/issues", - "source": "https://github.com/php-fig/container/tree/1.1.1" + "source": "https://github.com/php-fig/container/tree/1.1.2" }, - "time": "2021-03-05T17:36:06+00:00" + "time": "2021-11-05T16:50:12+00:00" }, { "name": "psr/http-client", - "version": "1.0.1", + "version": "1.0.2", "source": { "type": "git", "url": "https://github.com/php-fig/http-client.git", - "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" + "reference": "0955afe48220520692d2d09f7ab7e0f93ffd6a31" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", - "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/0955afe48220520692d2d09f7ab7e0f93ffd6a31", + "reference": "0955afe48220520692d2d09f7ab7e0f93ffd6a31", "shasum": "" }, "require": { "php": "^7.0 || ^8.0", - "psr/http-message": "^1.0" + "psr/http-message": "^1.0 || ^2.0" }, "type": "library", "extra": { @@ -650,7 +658,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common interface for HTTP clients", @@ -662,27 +670,27 @@ "psr-18" ], "support": { - "source": "https://github.com/php-fig/http-client/tree/master" + "source": "https://github.com/php-fig/http-client/tree/1.0.2" }, - "time": "2020-06-29T06:28:15+00:00" + "time": "2023-04-10T20:12:12+00:00" }, { "name": "psr/http-factory", - "version": "1.0.1", + "version": "1.0.2", "source": { "type": "git", "url": "https://github.com/php-fig/http-factory.git", - "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be" + "reference": "e616d01114759c4c489f93b099585439f795fe35" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-factory/zipball/12ac7fcd07e5b077433f5f2bee95b3a771bf61be", - "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be", + "url": "https://api.github.com/repos/php-fig/http-factory/zipball/e616d01114759c4c489f93b099585439f795fe35", + "reference": "e616d01114759c4c489f93b099585439f795fe35", "shasum": "" }, "require": { "php": ">=7.0.0", - "psr/http-message": "^1.0" + "psr/http-message": "^1.0 || ^2.0" }, "type": "library", "extra": { @@ -702,7 +710,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common interfaces for PSR-7 HTTP message factories", @@ -717,31 +725,31 @@ "response" ], "support": { - "source": "https://github.com/php-fig/http-factory/tree/master" + "source": "https://github.com/php-fig/http-factory/tree/1.0.2" }, - "time": "2019-04-30T12:38:16+00:00" + "time": "2023-04-10T20:10:41+00:00" }, { "name": "psr/http-message", - "version": "1.0.1", + "version": "2.0", "source": { "type": "git", "url": "https://github.com/php-fig/http-message.git", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/402d35bcb92c70c026d1a6a9883f06b2ead23d71", + "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -756,7 +764,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common interface for HTTP messages", @@ -770,9 +778,9 @@ "response" ], "support": { - "source": "https://github.com/php-fig/http-message/tree/master" + "source": "https://github.com/php-fig/http-message/tree/2.0" }, - "time": "2016-08-06T14:39:51+00:00" + "time": "2023-04-04T09:54:51+00:00" }, { "name": "ralouphie/getallheaders", @@ -820,25 +828,25 @@ }, { "name": "symfony/deprecation-contracts", - "version": "v2.4.0", + "version": "v3.3.0", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627" + "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5f38c8804a9e97d23e0c8d63341088cd8a22d627", - "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/7c3aff79d10325257a001fcf92d991f24fc967cf", + "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "2.4-dev" + "dev-main": "3.4-dev" }, "thanks": { "name": "symfony/contracts", @@ -867,7 +875,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v2.4.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.3.0" }, "funding": [ { @@ -883,35 +891,36 @@ "type": "tidelift" } ], - "time": "2021-03-23T23:28:01+00:00" + "time": "2023-05-23T14:45:45+00:00" } ], "packages-dev": [ { "name": "doctrine/instantiator", - "version": "1.4.0", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b" + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/d56bf6102915de5702778fe20f2de3b2fe570b5b", - "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", "shasum": "" }, "require": { - "php": "^7.1 || ^8.0" + "php": "^8.1" }, "require-dev": { - "doctrine/coding-standard": "^8.0", + "doctrine/coding-standard": "^11", "ext-pdo": "*", "ext-phar": "*", - "phpbench/phpbench": "^0.13 || 1.0.0-alpha2", - "phpstan/phpstan": "^0.12", - "phpstan/phpstan-phpunit": "^0.12", - "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0" + "phpbench/phpbench": "^1.2", + "phpstan/phpstan": "^1.9.4", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5.27", + "vimeo/psalm": "^5.4" }, "type": "library", "autoload": { @@ -938,7 +947,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/1.4.0" + "source": "https://github.com/doctrine/instantiator/tree/2.0.0" }, "funding": [ { @@ -954,41 +963,42 @@ "type": "tidelift" } ], - "time": "2020-11-10T18:47:58+00:00" + "time": "2022-12-30T00:23:10+00:00" }, { "name": "myclabs/deep-copy", - "version": "1.10.2", + "version": "1.11.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220" + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/776f831124e9c62e1a2c601ecc52e776d8bb7220", - "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, - "replace": { - "myclabs/deep-copy": "self.version" + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3,<3.2.2" }, "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^7.1" + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" }, "type": "library", "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - }, "files": [ "src/DeepCopy/deep_copy.php" - ] + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1004,7 +1014,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.10.2" + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.1" }, "funding": [ { @@ -1012,20 +1022,20 @@ "type": "tidelift" } ], - "time": "2020-11-13T09:40:50+00:00" + "time": "2023-03-08T13:26:56+00:00" }, { "name": "nikic/php-parser", - "version": "v4.13.1", + "version": "v4.17.1", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "63a79e8daa781cac14e5195e63ed8ae231dd10fd" + "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/63a79e8daa781cac14e5195e63ed8ae231dd10fd", - "reference": "63a79e8daa781cac14e5195e63ed8ae231dd10fd", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", "shasum": "" }, "require": { @@ -1066,9 +1076,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.13.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.17.1" }, - "time": "2021-11-03T20:52:16+00:00" + "time": "2023-08-13T19:53:39+00:00" }, { "name": "phar-io/manifest", @@ -1132,16 +1142,16 @@ }, { "name": "phar-io/version", - "version": "3.1.0", + "version": "3.2.1", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "bae7c545bef187884426f042434e561ab1ddb182" + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/bae7c545bef187884426f042434e561ab1ddb182", - "reference": "bae7c545bef187884426f042434e561ab1ddb182", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", "shasum": "" }, "require": { @@ -1177,256 +1187,29 @@ "description": "Library for handling version information and constraints", "support": { "issues": "https://github.com/phar-io/version/issues", - "source": "https://github.com/phar-io/version/tree/3.1.0" - }, - "time": "2021-02-23T14:00:09+00:00" - }, - { - "name": "phpdocumentor/reflection-common", - "version": "2.2.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/1d01c49d4ed62f25aa84a747ad35d5a16924662b", - "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b", - "shasum": "" - }, - "require": { - "php": "^7.2 || ^8.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-2.x": "2.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jaap van Otterdijk", - "email": "opensource@ijaap.nl" - } - ], - "description": "Common reflection classes used by phpdocumentor to reflect the code structure", - "homepage": "http://www.phpdoc.org", - "keywords": [ - "FQSEN", - "phpDocumentor", - "phpdoc", - "reflection", - "static analysis" - ], - "support": { - "issues": "https://github.com/phpDocumentor/ReflectionCommon/issues", - "source": "https://github.com/phpDocumentor/ReflectionCommon/tree/2.x" - }, - "time": "2020-06-27T09:03:43+00:00" - }, - { - "name": "phpdocumentor/reflection-docblock", - "version": "5.3.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "622548b623e81ca6d78b721c5e029f4ce664f170" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/622548b623e81ca6d78b721c5e029f4ce664f170", - "reference": "622548b623e81ca6d78b721c5e029f4ce664f170", - "shasum": "" - }, - "require": { - "ext-filter": "*", - "php": "^7.2 || ^8.0", - "phpdocumentor/reflection-common": "^2.2", - "phpdocumentor/type-resolver": "^1.3", - "webmozart/assert": "^1.9.1" - }, - "require-dev": { - "mockery/mockery": "~1.3.2", - "psalm/phar": "^4.8" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - }, - { - "name": "Jaap van Otterdijk", - "email": "account@ijaap.nl" - } - ], - "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "support": { - "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues", - "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/5.3.0" + "source": "https://github.com/phar-io/version/tree/3.2.1" }, - "time": "2021-10-19T17:43:47+00:00" - }, - { - "name": "phpdocumentor/type-resolver", - "version": "1.5.1", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "a12f7e301eb7258bb68acd89d4aefa05c2906cae" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/a12f7e301eb7258bb68acd89d4aefa05c2906cae", - "reference": "a12f7e301eb7258bb68acd89d4aefa05c2906cae", - "shasum": "" - }, - "require": { - "php": "^7.2 || ^8.0", - "phpdocumentor/reflection-common": "^2.0" - }, - "require-dev": { - "ext-tokenizer": "*", - "psalm/phar": "^4.8" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-1.x": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - } - ], - "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", - "support": { - "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.5.1" - }, - "time": "2021-10-02T14:08:47+00:00" - }, - { - "name": "phpspec/prophecy", - "version": "1.14.0", - "source": { - "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e", - "reference": "d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.2", - "php": "^7.2 || ~8.0, <8.2", - "phpdocumentor/reflection-docblock": "^5.2", - "sebastian/comparator": "^3.0 || ^4.0", - "sebastian/recursion-context": "^3.0 || ^4.0" - }, - "require-dev": { - "phpspec/phpspec": "^6.0 || ^7.0", - "phpunit/phpunit": "^8.0 || ^9.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Prophecy\\": "src/Prophecy" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" - } - ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "support": { - "issues": "https://github.com/phpspec/prophecy/issues", - "source": "https://github.com/phpspec/prophecy/tree/1.14.0" - }, - "time": "2021-09-10T09:02:12+00:00" + "time": "2022-02-21T01:04:05+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "9.2.8", + "version": "9.2.29", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "cf04e88a2e3c56fc1a65488afd493325b4c1bc3e" + "reference": "6a3a87ac2bbe33b25042753df8195ba4aa534c76" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/cf04e88a2e3c56fc1a65488afd493325b4c1bc3e", - "reference": "cf04e88a2e3c56fc1a65488afd493325b4c1bc3e", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/6a3a87ac2bbe33b25042753df8195ba4aa534c76", + "reference": "6a3a87ac2bbe33b25042753df8195ba4aa534c76", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.13.0", + "nikic/php-parser": "^4.15", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -1441,8 +1224,8 @@ "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-pcov": "*", - "ext-xdebug": "*" + "ext-pcov": "PHP extension that provides line coverage", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, "type": "library", "extra": { @@ -1475,7 +1258,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.8" + "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.29" }, "funding": [ { @@ -1483,20 +1267,20 @@ "type": "github" } ], - "time": "2021-10-30T08:01:38+00:00" + "time": "2023-09-19T04:57:46+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "3.0.5", + "version": "3.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", - "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", "shasum": "" }, "require": { @@ -1535,7 +1319,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" }, "funding": [ { @@ -1543,7 +1327,7 @@ "type": "github" } ], - "time": "2020-09-28T05:57:25+00:00" + "time": "2021-12-02T12:48:52+00:00" }, { "name": "phpunit/php-invoker", @@ -1728,20 +1512,20 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.10", + "version": "9.6.13", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a" + "reference": "f3d767f7f9e191eab4189abe41ab37797e30b1be" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c814a05837f2edb0d1471d6e3f4ab3501ca3899a", - "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/f3d767f7f9e191eab4189abe41ab37797e30b1be", + "reference": "f3d767f7f9e191eab4189abe41ab37797e30b1be", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.3.1", + "doctrine/instantiator": "^1.3.1 || ^2", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", @@ -1752,31 +1536,26 @@ "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", "php": ">=7.3", - "phpspec/prophecy": "^1.12.1", - "phpunit/php-code-coverage": "^9.2.7", + "phpunit/php-code-coverage": "^9.2.28", "phpunit/php-file-iterator": "^3.0.5", "phpunit/php-invoker": "^3.1.1", "phpunit/php-text-template": "^2.0.3", "phpunit/php-timer": "^5.0.2", "sebastian/cli-parser": "^1.0.1", "sebastian/code-unit": "^1.0.6", - "sebastian/comparator": "^4.0.5", + "sebastian/comparator": "^4.0.8", "sebastian/diff": "^4.0.3", "sebastian/environment": "^5.1.3", - "sebastian/exporter": "^4.0.3", + "sebastian/exporter": "^4.0.5", "sebastian/global-state": "^5.0.1", "sebastian/object-enumerator": "^4.0.3", "sebastian/resource-operations": "^3.0.3", - "sebastian/type": "^2.3.4", + "sebastian/type": "^3.2", "sebastian/version": "^3.0.2" }, - "require-dev": { - "ext-pdo": "*", - "phpspec/prophecy-phpunit": "^2.0.1" - }, "suggest": { - "ext-soap": "*", - "ext-xdebug": "*" + "ext-soap": "To be able to generate mocks based on WSDL files", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, "bin": [ "phpunit" @@ -1784,15 +1563,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "9.5-dev" + "dev-master": "9.6-dev" } }, "autoload": { - "classmap": [ - "src/" - ], "files": [ "src/Framework/Assert/Functions.php" + ], + "classmap": [ + "src/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -1815,19 +1594,24 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.10" + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.13" }, "funding": [ { - "url": "https://phpunit.de/donate.html", + "url": "https://phpunit.de/sponsors.html", "type": "custom" }, { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", + "type": "tidelift" } ], - "time": "2021-09-25T07:38:51+00:00" + "time": "2023-09-19T05:39:22+00:00" }, { "name": "sebastian/cli-parser", @@ -1998,16 +1782,16 @@ }, { "name": "sebastian/comparator", - "version": "4.0.6", + "version": "4.0.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "55f4261989e546dc112258c7a75935a81a7ce382" + "reference": "fa0f136dd2334583309d32b62544682ee972b51a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", - "reference": "55f4261989e546dc112258c7a75935a81a7ce382", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", + "reference": "fa0f136dd2334583309d32b62544682ee972b51a", "shasum": "" }, "require": { @@ -2060,7 +1844,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" }, "funding": [ { @@ -2068,7 +1852,7 @@ "type": "github" } ], - "time": "2020-10-26T15:49:45+00:00" + "time": "2022-09-14T12:41:17+00:00" }, { "name": "sebastian/complexity", @@ -2129,16 +1913,16 @@ }, { "name": "sebastian/diff", - "version": "4.0.4", + "version": "4.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", - "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/74be17022044ebaaecfdf0c5cd504fc9cd5a7131", + "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131", "shasum": "" }, "require": { @@ -2183,7 +1967,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.5" }, "funding": [ { @@ -2191,20 +1975,20 @@ "type": "github" } ], - "time": "2020-10-26T13:10:38+00:00" + "time": "2023-05-07T05:35:17+00:00" }, { "name": "sebastian/environment", - "version": "5.1.3", + "version": "5.1.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "388b6ced16caa751030f6a69e588299fa09200ac" + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", - "reference": "388b6ced16caa751030f6a69e588299fa09200ac", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", "shasum": "" }, "require": { @@ -2246,7 +2030,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" }, "funding": [ { @@ -2254,20 +2038,20 @@ "type": "github" } ], - "time": "2020-09-28T05:52:38+00:00" + "time": "2023-02-03T06:03:51+00:00" }, { "name": "sebastian/exporter", - "version": "4.0.3", + "version": "4.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" + "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", - "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", + "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", "shasum": "" }, "require": { @@ -2316,14 +2100,14 @@ } ], "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", + "homepage": "https://www.github.com/sebastianbergmann/exporter", "keywords": [ "export", "exporter" ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.5" }, "funding": [ { @@ -2331,20 +2115,20 @@ "type": "github" } ], - "time": "2020-09-28T05:24:23+00:00" + "time": "2022-09-14T06:03:37+00:00" }, { "name": "sebastian/global-state", - "version": "5.0.3", + "version": "5.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "23bd5951f7ff26f12d4e3242864df3e08dec4e49" + "reference": "bde739e7565280bda77be70044ac1047bc007e34" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/23bd5951f7ff26f12d4e3242864df3e08dec4e49", - "reference": "23bd5951f7ff26f12d4e3242864df3e08dec4e49", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bde739e7565280bda77be70044ac1047bc007e34", + "reference": "bde739e7565280bda77be70044ac1047bc007e34", "shasum": "" }, "require": { @@ -2387,7 +2171,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.3" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.6" }, "funding": [ { @@ -2395,7 +2179,7 @@ "type": "github" } ], - "time": "2021-06-11T13:31:12+00:00" + "time": "2023-08-02T09:26:13+00:00" }, { "name": "sebastian/lines-of-code", @@ -2568,16 +2352,16 @@ }, { "name": "sebastian/recursion-context", - "version": "4.0.4", + "version": "4.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", - "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", "shasum": "" }, "require": { @@ -2616,10 +2400,10 @@ } ], "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", + "homepage": "https://github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" }, "funding": [ { @@ -2627,7 +2411,7 @@ "type": "github" } ], - "time": "2020-10-26T13:17:30+00:00" + "time": "2023-02-03T06:07:39+00:00" }, { "name": "sebastian/resource-operations", @@ -2686,28 +2470,28 @@ }, { "name": "sebastian/type", - "version": "2.3.4", + "version": "3.2.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "b8cd8a1c753c90bc1a0f5372170e3e489136f914" + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/b8cd8a1c753c90bc1a0f5372170e3e489136f914", - "reference": "b8cd8a1c753c90bc1a0f5372170e3e489136f914", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", "shasum": "" }, "require": { "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^9.5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.3-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -2730,7 +2514,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/2.3.4" + "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" }, "funding": [ { @@ -2738,7 +2522,7 @@ "type": "github" } ], - "time": "2021-06-15T12:49:02+00:00" + "time": "2023-02-03T06:13:03+00:00" }, { "name": "sebastian/version", @@ -2793,85 +2577,6 @@ ], "time": "2020-09-28T06:39:44+00:00" }, - { - "name": "symfony/polyfill-ctype", - "version": "v1.23.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "suggest": { - "ext-ctype": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "1.23-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Gert de Pagter", - "email": "BackEndTea@gmail.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for ctype functions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "ctype", - "polyfill", - "portable" - ], - "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2021-02-19T12:13:01+00:00" - }, { "name": "theseer/tokenizer", "version": "1.2.1", @@ -2921,64 +2626,6 @@ } ], "time": "2021-07-28T10:34:58+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.10.0", - "source": { - "type": "git", - "url": "https://github.com/webmozarts/assert.git", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", - "shasum": "" - }, - "require": { - "php": "^7.2 || ^8.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "phpstan/phpstan": "<0.12.20", - "vimeo/psalm": "<4.6.1 || 4.6.2" - }, - "require-dev": { - "phpunit/phpunit": "^8.5.13" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.10-dev" - } - }, - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "support": { - "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.10.0" - }, - "time": "2021-03-09T10:59:23+00:00" } ], "aliases": [], @@ -2988,5 +2635,5 @@ "prefer-lowest": false, "platform": [], "platform-dev": [], - "plugin-api-version": "2.1.0" + "plugin-api-version": "2.2.0" } diff --git a/examples/exAuthGetAccessToken.php b/examples/exAuthGetAccessToken.php index f0dd9a0..da77fe9 100644 --- a/examples/exAuthGetAccessToken.php +++ b/examples/exAuthGetAccessToken.php @@ -3,16 +3,16 @@ /** * This example illustrations how to generate an enterprise access token similar to what is documented here: * - * https://developer.box.com/v2.0/docs/authentication-with-jwt#section-3-generate-an-enterprise-access-token-with-box-sdks + * https://developer.box.com/guides/authentication/jwt/user-access-tokens/ */ require_once (__DIR__ . '/../bootstrap/autoload.php'); require_once (__DIR__ . '/exHelpers.php'); use Box\Auth\BoxJWTAuth; -use Box\BoxClient; +use Box\Config\BoxConstants; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); diff --git a/examples/exFilesCopyFile.php b/examples/exFilesCopyFile.php index b77f64e..b9850c4 100644 --- a/examples/exFilesCopyFile.php +++ b/examples/exFilesCopyFile.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; @@ -54,4 +54,3 @@ $copiedFileParent = end($copiedFileObject->path_collection->entries); echo "Parent ID: {$copiedFileParent->id}\n"; echo "Parent Name: {$copiedFileParent->name}\n"; - diff --git a/examples/exFilesDeleteFile.php b/examples/exFilesDeleteFile.php index 1837db6..ff17045 100644 --- a/examples/exFilesDeleteFile.php +++ b/examples/exFilesDeleteFile.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; @@ -46,4 +46,3 @@ // delete file $res = $boxClient->filesManager->deleteFile($uploadedFileObject->id, $headers); echo $res->getStatusCode(); - diff --git a/examples/exFilesDownloadFile.php b/examples/exFilesDownloadFile.php index 11ee426..e524efc 100644 --- a/examples/exFilesDownloadFile.php +++ b/examples/exFilesDownloadFile.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; @@ -46,4 +46,3 @@ // download file $res = $boxClient->filesManager->downloadFile($uploadedFileObject->id, 'downloadedFile.txt', null, $headers); echo $res->getStatusCode(); - diff --git a/examples/exFilesGetEmbedLink.php b/examples/exFilesGetEmbedLink.php index 180647c..5249ff6 100644 --- a/examples/exFilesGetEmbedLink.php +++ b/examples/exFilesGetEmbedLink.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFilesGetFileInfo.php b/examples/exFilesGetFileInfo.php index 4580497..f520391 100644 --- a/examples/exFilesGetFileInfo.php +++ b/examples/exFilesGetFileInfo.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFilesGetThumbNail.php b/examples/exFilesGetThumbNail.php index e8b1891..541535b 100644 --- a/examples/exFilesGetThumbNail.php +++ b/examples/exFilesGetThumbNail.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFilesSearch.php b/examples/exFilesSearch.php index 78bea04..6b1ed95 100644 --- a/examples/exFilesSearch.php +++ b/examples/exFilesSearch.php @@ -9,7 +9,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -18,7 +18,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFilesUploadFile.php b/examples/exFilesUploadFile.php index 4a7dc3c..a7dd96d 100644 --- a/examples/exFilesUploadFile.php +++ b/examples/exFilesUploadFile.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersCopyFolder.php b/examples/exFoldersCopyFolder.php index 2881c32..a5bd1e5 100644 --- a/examples/exFoldersCopyFolder.php +++ b/examples/exFoldersCopyFolder.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersCreateFolder.php b/examples/exFoldersCreateFolder.php index d381ec9..3b658e0 100644 --- a/examples/exFoldersCreateFolder.php +++ b/examples/exFoldersCreateFolder.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersDeleteFolder.php b/examples/exFoldersDeleteFolder.php index 5401a1d..c47a876 100644 --- a/examples/exFoldersDeleteFolder.php +++ b/examples/exFoldersDeleteFolder.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersGetFolderInfo.php b/examples/exFoldersGetFolderInfo.php index 74f7d83..81cf64d 100644 --- a/examples/exFoldersGetFolderInfo.php +++ b/examples/exFoldersGetFolderInfo.php @@ -9,7 +9,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -18,7 +18,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersGetFolderItems.php b/examples/exFoldersGetFolderItems.php index 89ce58b..e09b0ba 100644 --- a/examples/exFoldersGetFolderItems.php +++ b/examples/exFoldersGetFolderItems.php @@ -9,7 +9,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -18,7 +18,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersSearch.php b/examples/exFoldersSearch.php index 3185711..bb45966 100644 --- a/examples/exFoldersSearch.php +++ b/examples/exFoldersSearch.php @@ -9,7 +9,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -18,7 +18,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exFoldersUpdateFolder.php b/examples/exFoldersUpdateFolder.php index 218af47..e9a64f8 100644 --- a/examples/exFoldersUpdateFolder.php +++ b/examples/exFoldersUpdateFolder.php @@ -10,7 +10,7 @@ $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -19,7 +19,7 @@ $users = json_decode($res->getBody()); if (!$users->total_count) { - return "No users found for $userLogin.\n"; + die("No users found for $userLogin.\n"); } $user = $users->entries[0]; diff --git a/examples/exUsersCreateAppUser.php b/examples/exUsersCreateAppUser.php index 4fc1b26..d2dbb13 100644 --- a/examples/exUsersCreateAppUser.php +++ b/examples/exUsersCreateAppUser.php @@ -5,8 +5,9 @@ use Box\Auth\BoxJWTAuth; use Box\BoxClient; +use Box\Config\BoxConstants; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); diff --git a/examples/exUsersGetEnterpriseUser.php b/examples/exUsersGetEnterpriseUser.php index 93bd77c..e6ff50f 100644 --- a/examples/exUsersGetEnterpriseUser.php +++ b/examples/exUsersGetEnterpriseUser.php @@ -5,10 +5,11 @@ use Box\Auth\BoxJWTAuth; use Box\BoxClient; +use Box\Config\BoxConstants; $userLogin = ''; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); @@ -16,4 +17,3 @@ $res = $boxClient->usersManager->getEnterpriseUsers(null, $userLogin); $users = json_decode($res->getBody()); var_dump($users); - diff --git a/examples/exUsersGetMe.php b/examples/exUsersGetMe.php index 2f6b33c..ec77dc4 100644 --- a/examples/exUsersGetMe.php +++ b/examples/exUsersGetMe.php @@ -3,7 +3,7 @@ /** * This example illustrations how to generate an enterprise access token similar to what is documented here: * - * https://developer.box.com/v2.0/docs/authentication-with-jwt#section-3-generate-an-enterprise-access-token-with-box-sdks + * https://developer.box.com/guides/authentication/jwt/user-access-tokens/ */ require_once (__DIR__ . '/../bootstrap/autoload.php'); @@ -11,8 +11,9 @@ use Box\Auth\BoxJWTAuth; use Box\BoxClient; +use Box\Config\BoxConstants; -$boxJwt = new BoxJWTAuth(); +$boxJwt = new BoxJWTAuth(null, __DIR__ . '/../' . BoxConstants::CONFIG_PATH); $boxConfig = $boxJwt->getBoxConfig(); $adminToken = $boxJwt->adminToken(); $boxClient = new BoxClient($boxConfig, $adminToken->access_token); diff --git a/src/Config/BoxConstants.php b/src/Config/BoxConstants.php index 37250a6..adcdced 100644 --- a/src/Config/BoxConstants.php +++ b/src/Config/BoxConstants.php @@ -150,7 +150,7 @@ abstract class BoxConstants ]; /** Error codes ************************************************************ - * https://developer.box.com/docs/error-codes + * https://developer.box.com/guides/api-calls/permissions-and-errors/common-errors/#common-error-codes **************************************************************************/ // 400 Bad Request diff --git a/src/Managers/BoxFilesManager.php b/src/Managers/BoxFilesManager.php index ca03461..8998678 100644 --- a/src/Managers/BoxFilesManager.php +++ b/src/Managers/BoxFilesManager.php @@ -66,7 +66,7 @@ public function searchFilesByName($query, $offset = null, $limit = null, $fields /** * Get file info. * - * https://developer.box.com/reference#files + * https://developer.box.com/reference/resources/file/ * * @param string $id File id. * @param string $fields Array of fields to return in response. @@ -87,7 +87,7 @@ public function getFileInfo($id, $fields, $additionalHeaders = null, $runAsync = /** * Upload a file. * - * https://developer.box.com/v2.0/reference#upload-a-file + * https://developer.box.com/reference/post-files-content * * @param \Box\Models\Request\BoxFileRequest $fileRequest BoxFileRequest instance. * @param string|resource|\Psr\Http\Message\StreamInterface $file File path, file resource or @@ -154,7 +154,7 @@ public function uploadFileVersion(BoxFileRequest $fileRequest, $file, $fileID, $ /** * Delete file. * - * https://developer.box.com/reference#delete-a-file + * https://developer.box.com/reference/delete-files-id * * @param string $id File id. * @param string[] $additionalHeaders Additional HTTP header key-value pairs. @@ -173,7 +173,7 @@ public function deleteFile($id, $additionalHeaders = null, $runAsync = false) /** * Copy a file. * - * https://developer.box.com/v2.0/reference#copy-a-file + * https://developer.box.com/reference/post-files-id-copy * * @param string $sourceFileId Source file id. * @param string $destinationFolderId Destination folder id. Root folder is always '0'. @@ -206,7 +206,7 @@ public function copyFile($sourceFileId, $destinationFolderId, $newName = null, $ * download is a file path, the handle to that file will still be open and will be in the body of the response. * You can get the response from the exception. * - * https://developer.box.com/reference#download-a-file + * https://developer.box.com/reference/get-files-id-content * * @param string $fileId File id. * @param string|resource|\Psr\Http\Message\StreamInterface $sink Where the downloaded file will be @@ -231,7 +231,7 @@ public function downloadFile($fileId, $sink, $version = null, $additionalHeaders /** * Get file thumbnail. * - * https://developer.box.com/reference#get-a-thumbnail-for-a-file + * https://developer.box.com/reference/get-files-id-thumbnail-id * * From Box documentation: * @@ -239,7 +239,7 @@ public function downloadFile($fileId, $sink, $version = null, $additionalHeaders * 160x160, and 320x320 can be returned in the .jpg format. Thumbnails can be generated for the image and video * file formats listed here: * - * http://community.box.com/t5/Managing-Your-Content/What-file-types-are-supported-by-Box-s-Content-Preview/ta-p/327 + * https://support.box.com/hc/en-us/articles/360043695794-Viewing-Different-File-Types-Supported-in-Box-Content-Preview * * @param string $id File id. * @param string $extension File extension, e.g. "png" or "jpg" diff --git a/src/Managers/BoxFoldersManager.php b/src/Managers/BoxFoldersManager.php index 5e52503..e55af2a 100644 --- a/src/Managers/BoxFoldersManager.php +++ b/src/Managers/BoxFoldersManager.php @@ -32,7 +32,7 @@ function __construct($boxClient) /** * Search folder by name. * - * https://developer.box.com/reference#searching-for-content + * https://developer.box.com/reference/get-search * * @param string $query Folder name query string. * @param int $offset The offset of the item at which to begin the response. @@ -65,7 +65,7 @@ public function searchFolderByName($query, $offset = null, $limit = null, $field /** * Get folder info. * - * https://developer.box.com/reference#get-folder-info + * https://developer.box.com/reference/get-folders-id * * @param string $id Folder id. Root folder is always '0'. * @param string $fields Array of fields to return in response. @@ -86,7 +86,7 @@ public function getFolderInfo($id, $fields, $additionalHeaders = null, $runAsync /** * Get folder items. * - * https://developer.box.com/reference#get-a-folders-items + * https://developer.box.com/reference/get-folders-id#get-folders-id-items * * @param string $id Folder id. Root folder is always '0'. * @param int $offset The offset of the item at which to begin the response. @@ -114,7 +114,7 @@ public function getFolderItems($id, $offset = 0, $limit = null, $fields = null, /** * Create folder. * - * https://developer.box.com/reference#create-a-new-folder + * https://developer.box.com/reference/post-folders/ * * @param \Box\Models\Request\BoxFolderRequest $folderRequest * @param string[] $fields Array of fields to return in response. @@ -151,7 +151,7 @@ public function createFolder(BoxFolderRequest $folderRequest, $fields = null, $a /** * Copy a folder. * - * https://developer.box.com/reference#copy-a-folder + * https://developer.box.com/reference/post-folders-id-copy/ * * @param string $sourceFolderId Source folder id. * @param string $destinationFolderId Destination folder id. Root folder is always '0'. @@ -180,7 +180,7 @@ public function copyFolder($sourceFolderId, $destinationFolderId, $newName = nul /** * Delete folder. * - * https://developer.box.com/reference#delete-a-folder + * https://developer.box.com/reference/delete-folders-id/ * * @param string $id Folder id. * @param bool $recursive Whether to delete this folder if it has items inside of it. @@ -202,7 +202,7 @@ public function deleteFolder($id, $recursive = null, $additionalHeaders = null, /** * Update folder. * - * https://developer.box.com/reference#update-information-about-a-folder + * https://developer.box.com/reference/put-folders-id/ * * @param \Box\Models\Request\BoxFolderRequest $folderRequest * @param string[] $fields Array of fields to return in response. diff --git a/src/Managers/BoxResourceManager.php b/src/Managers/BoxResourceManager.php index 0eda97f..5bb76bf 100644 --- a/src/Managers/BoxResourceManager.php +++ b/src/Managers/BoxResourceManager.php @@ -191,7 +191,7 @@ function executeBoxRequest($request, $options = []) } /** - * Resolve Box request synchronously or asyncrhonously. + * Resolve Box request synchronously or asynchronously. * * @param \GuzzleHttp\Psr7\Request $request Box (Guzzle) request instance. * @param array $options Guzzle request options. diff --git a/src/Managers/BoxUsersManager.php b/src/Managers/BoxUsersManager.php index 08e22e8..0f01e18 100644 --- a/src/Managers/BoxUsersManager.php +++ b/src/Managers/BoxUsersManager.php @@ -29,8 +29,7 @@ function __construct($boxClient) * If you're creating an app user, 'is_platform_access_only' must be set to true * in the $userRequest array. * - * https://developer.box.com/reference#create-an-enterprise-user - * https://developer.box.com/reference#create-app-user + * https://developer.box.com/reference/post-users/ * * @param stirng[] $userRequest Array of user request * @param string $fields Array of fields to return in response. @@ -51,7 +50,7 @@ public function createEnterpriseUser($userRequest, $fields = null, $runAsync = f /** * Get enterprise user. Only available to admin accounts or service accounts. * - * https://developer.box.com/reference#get-all-users-in-an-enterprise + * https://developer.box.com/reference/get-users * * @param string $userType The type of user to search for. One of all, external or managed. * The default is managed. diff --git a/src/Models/BoxModel.php b/src/Models/BoxModel.php index 5770f86..874ab0f 100644 --- a/src/Models/BoxModel.php +++ b/src/Models/BoxModel.php @@ -23,7 +23,7 @@ public function __construct() * * @return array */ - public function jsonSerialize() + public function jsonSerialize(): array { return $this->params; }