diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1dda020 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +!.gitignore +composer.phar +vendor diff --git a/composer.json b/composer.json new file mode 100644 index 0000000..b48b88e --- /dev/null +++ b/composer.json @@ -0,0 +1,55 @@ +{ + "name": "mirzaev/vk-robot-bobby", + "description": "Бобби Мирзаев - чат-робот ВКонтакте для проведения ролевых игр", + "readme": "README.md", + "keywords": [ + "Bobby", + "Mirzaev", + "vk", + "chat-robot", + "roleplay" + ], + "type": "robot", + "license": "WTFPL", + "homepage": "https://git.mirzaev.sexy/mirzaev/vk-robot-bobby", + "authors": [ + { + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://hood.su/mirzaev", + "role": "Father" + } + ], + "support": { + "email": "arsen@mirzaev.sexy", + "wiki": "https://git.mirzaev.sexy/mirzaev/vk-robot-bobby/wiki", + "issues": "https://git.mirzaev.sexy/mirzaev/vk-robot-bobby/issues", + "chat": "https://vk.me/bobby.mirzaev.sexy" + }, + "funding": [ + { + "type": "funding", + "url": "https://fund.mirzaev.sexy" + } + ], + "minimum-stability": "dev", + "require": { + "php": "^8.1", + "triagens/arangodb": "~3.8", + "guzzlehttp/guzzle": "^7.4", + "mirzaev/arangodb": "^1.0", + "mirzaev/vk": "^4.2", + "mirzaev/vk-arangodb": "^1.0.1", + "mirzaev/vk-chat": "^1.0" + }, + "autoload": { + "psr-4": { + "mirzaev\\vk\\robot\\bobby\\": "mirzaev/vk/robot/bobby/system" + } + }, + "autoload-dev": { + "psr-4": { + "mirzaev\\vk\\robot\\bobby\\tests\\": "mirzaev/vk/robot/bobby/tests" + } + } +} diff --git a/composer.lock b/composer.lock new file mode 100644 index 0000000..8d9debe --- /dev/null +++ b/composer.lock @@ -0,0 +1,1137 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", + "This file is @generated automatically" + ], + "content-hash": "ab14cf737c9cf81d65b0e8bb20a7c4f8", + "packages": [ + { + "name": "guzzlehttp/guzzle", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/guzzle/guzzle.git", + "reference": "8459341c16f96b9610dcdfe22bd3060d60c0da04" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/8459341c16f96b9610dcdfe22bd3060d60c0da04", + "reference": "8459341c16f96b9610dcdfe22bd3060d60c0da04", + "shasum": "" + }, + "require": { + "ext-json": "*", + "guzzlehttp/promises": "^1.5", + "guzzlehttp/psr7": "^1.9 || ^2.4", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0", + "symfony/deprecation-contracts": "^2.2 || ^3.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.1", + "ext-curl": "*", + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.29 || ^9.5.23", + "psr/log": "^1.1 || ^2.0 || ^3.0" + }, + "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" + }, + "default-branch": true, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": false + }, + "branch-alias": { + "dev-master": "7.5-dev" + } + }, + "autoload": { + "files": [ + "src/functions_include.php" + ], + "psr-4": { + "GuzzleHttp\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Jeremy Lindblom", + "email": "jeremeamia@gmail.com", + "homepage": "https://github.com/jeremeamia" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" + } + ], + "description": "Guzzle is a PHP HTTP client library", + "keywords": [ + "client", + "curl", + "framework", + "http", + "http client", + "psr-18", + "psr-7", + "rest", + "web service" + ], + "support": { + "issues": "https://github.com/guzzle/guzzle/issues", + "source": "https://github.com/guzzle/guzzle/tree/master" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle", + "type": "tidelift" + } + ], + "time": "2022-08-29T11:03:19+00:00" + }, + { + "name": "guzzlehttp/promises", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/guzzle/promises.git", + "reference": "b94b2807d85443f9719887892882d0329d1e2598" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/promises/zipball/b94b2807d85443f9719887892882d0329d1e2598", + "reference": "b94b2807d85443f9719887892882d0329d1e2598", + "shasum": "" + }, + "require": { + "php": ">=5.5" + }, + "require-dev": { + "symfony/phpunit-bridge": "^4.4 || ^5.1" + }, + "default-branch": true, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.5-dev" + } + }, + "autoload": { + "files": [ + "src/functions_include.php" + ], + "psr-4": { + "GuzzleHttp\\Promise\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" + } + ], + "description": "Guzzle promises library", + "keywords": [ + "promise" + ], + "support": { + "issues": "https://github.com/guzzle/promises/issues", + "source": "https://github.com/guzzle/promises/tree/1.5.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/promises", + "type": "tidelift" + } + ], + "time": "2022-08-28T14:55:35+00:00" + }, + { + "name": "guzzlehttp/psr7", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/guzzle/psr7.git", + "reference": "67c26b443f348a51926030c83481b85718457d3d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/67c26b443f348a51926030c83481b85718457d3d", + "reference": "67c26b443f348a51926030c83481b85718457d3d", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0", + "psr/http-factory": "^1.0", + "psr/http-message": "^1.0", + "ralouphie/getallheaders": "^3.0" + }, + "provide": { + "psr/http-factory-implementation": "1.0", + "psr/http-message-implementation": "1.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.1", + "http-interop/http-factory-tests": "^0.9", + "phpunit/phpunit": "^8.5.29 || ^9.5.23" + }, + "suggest": { + "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" + }, + "default-branch": true, + "type": "library", + "extra": { + "bamarni-bin": { + "bin-links": true, + "forward-command": false + }, + "branch-alias": { + "dev-master": "2.4-dev" + } + }, + "autoload": { + "psr-4": { + "GuzzleHttp\\Psr7\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" + } + ], + "description": "PSR-7 message implementation that also provides common utility methods", + "keywords": [ + "http", + "message", + "psr-7", + "request", + "response", + "stream", + "uri", + "url" + ], + "support": { + "issues": "https://github.com/guzzle/psr7/issues", + "source": "https://github.com/guzzle/psr7/tree/2.4.3" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7", + "type": "tidelift" + } + ], + "time": "2022-10-26T14:07:24+00:00" + }, + { + "name": "jasny/error-handler", + "version": "v0.2.0", + "source": { + "type": "git", + "url": "https://github.com/jasny/error-handler.git", + "reference": "38e076fc36d86689010081bc2eab96f12d97b0d8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jasny/error-handler/zipball/38e076fc36d86689010081bc2eab96f12d97b0d8", + "reference": "38e076fc36d86689010081bc2eab96f12d97b0d8", + "shasum": "" + }, + "require": { + "php": ">=5.6.0", + "psr/http-message": "^1.0", + "psr/log": "^1.0" + }, + "require-dev": { + "jasny/http-message": "^1.3", + "jasny/php-code-quality": "^2.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Jasny\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Arnold Daniels", + "email": "arnold@jasny.net", + "homepage": "http://www.jasny.net" + } + ], + "description": "Error handler with PSR-7 support", + "keywords": [ + "error handler", + "exception handler", + "middleware" + ], + "support": { + "issues": "https://github.com/jasny/error-handler/issues", + "source": "https://github.com/jasny/error-handler" + }, + "abandoned": true, + "time": "2017-01-25T01:27:18+00:00" + }, + { + "name": "mirzaev/accounts", + "version": "1.2.x-dev", + "source": { + "type": "git", + "url": "https://git.mirzaev.sexy/mirzaev/accounts", + "reference": "4d6df00dc9538c99d8eced6deebab55f1af2bf8a" + }, + "require": { + "ext-dom": "20031129", + "ext-libxml": "~8.1.1", + "guzzlehttp/guzzle": "^7.2", + "php": "~8.1" + }, + "require-dev": { + "phpdocumentor/phpdocumentor": ">=2.9", + "phpunit/phpunit": "^9" + }, + "type": "library", + "autoload": { + "psr-4": { + "mirzaev\\accounts\\": "mirzaev/accounts/system" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "WTFPL" + ], + "authors": [ + { + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://mirzaev.sexy", + "role": "Programmer" + } + ], + "description": "Simple accounts manager", + "homepage": "https://git.mirzaev.sexy/mirzaev/accounts", + "keywords": [ + "accounts" + ], + "support": { + "email": "arsen@mirzaev.sexy", + "issues": "https://git.mirzaev.sexy/mirzaev/accounts/issues", + "wiki": "https://git.mirzaev.sexy/mirzaev/accounts/wiki" + }, + "funding": [ + { + "url": "https://fund.mirzaev.sexy", + "type": "funding" + } + ], + "time": "2022-11-05T23:48:10+00:00" + }, + { + "name": "mirzaev/arangodb", + "version": "1.0.2", + "source": { + "type": "git", + "url": "https://git.mirzaev.sexy/mirzaev/arangodb", + "reference": "e7da9978d01d3f8bdef6c74809dfb4eb8989f92c" + }, + "require": { + "php": "^8.1", + "triagens/arangodb": "~3.8" + }, + "require-dev": { + "phpunit/phpunit": "^9.3.3" + }, + "type": "library", + "autoload": { + "psr-4": { + "mirzaev\\arangodb\\": "mirzaev/arangodb/system" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "WTFPL" + ], + "authors": [ + { + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://mirzaev.sexy", + "role": "Developer" + } + ], + "description": "Simple PHP-framework for ArangoDB", + "homepage": "https://git.hood.su/mirzaev/arangodb", + "keywords": [ + "ArangoDb" + ], + "support": { + "email": "arsen@mirzaev.sexy", + "issues": "https://git.mirzaev.sexy/mirzaev/arangodb/issues", + "wiki": "https://git.mirzaev.sexy/mirzaev/arangodb/manual" + }, + "funding": [ + { + "url": "https://fund.mirzaev.sexy", + "type": "funding" + } + ], + "time": "2022-11-06T00:03:56+00:00" + }, + { + "name": "mirzaev/vk", + "version": "4.2.0", + "source": { + "type": "git", + "url": "https://git.mirzaev.sexy/mirzaev/vk", + "reference": "5bd94e5ca3ceeb73aeaa5d6db9fdef1586cfb155" + }, + "require": { + "guzzlehttp/guzzle": "~7.5", + "jasny/error-handler": "~0.2", + "mirzaev/accounts": "~1.2.0", + "monolog/monolog": "~1.6", + "php": "~8.1", + "psr/log": "~1.0" + }, + "require-dev": { + "phpunit/phpunit": "~9.5" + }, + "type": "framework", + "autoload": { + "psr-4": { + "mirzaev\\vk\\": "mirzaev/vk/system" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "WTFPL" + ], + "authors": [ + { + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://mirzaev.sexy/mirzaev", + "role": "Programmer" + } + ], + "description": "Framework for vk.com API", + "homepage": "https://git.mirzaev.sexy/mirzaev/vk", + "keywords": [ + "api", + "vk" + ], + "support": { + "docs": "https://git.mirzaev.sexy/mirzaev/vk/wiki", + "issues": "https://git.mirzaev.sexy/mirzaev/vk/issues" + }, + "time": "2022-11-07T16:06:13+00:00" + }, + { + "name": "mirzaev/vk-arangodb", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://git.mirzaev.sexy/mirzaev/vk-arangodb", + "reference": "9e17928451e84d27cd669043c0c6a3b4dc9f17ac" + }, + "require": { + "guzzlehttp/guzzle": "~7.5", + "mirzaev/accounts": "~1.2", + "mirzaev/arangodb": "~1.0", + "mirzaev/vk": "~4.0", + "php": "^8.1", + "triagens/arangodb": "~3.9.x-dev" + }, + "type": "vk-module", + "autoload": { + "psr-4": { + "mirzaev\\vk\\arangodb\\": "mirzaev/vk/arangodb/system" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "WTFPL" + ], + "authors": [ + { + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://mirzaev.sexy", + "role": "Programmer" + } + ], + "description": "Module for mirzaev/vk framework for storage data in ArangoDB", + "homepage": "https://git.mirzaev.sexy/mirzaev/vk-arangodb", + "keywords": [ + "ArangoDb", + "module", + "vk" + ], + "support": { + "email": "arsen@mirzaev.sexy", + "issues": "https://git.mirzaev.sexy/mirzaev/vk-arangodb/issues", + "wiki": "https://git.mirzaev.sexy/mirzaev/vk-arangodb/wiki" + }, + "funding": [ + { + "url": "https://fund.mirzaev.sexy", + "type": "funding" + } + ], + "time": "2022-11-07T04:09:30+00:00" + }, + { + "name": "mirzaev/vk-chat", + "version": "1.0.x-dev", + "source": { + "type": "git", + "url": "https://git.mirzaev.sexy/mirzaev/vk-chat", + "reference": "40ceb7a86c38a0b878adca44c5729407631e7e82" + }, + "require": { + "php": "^8.1" + }, + "type": "vk-module", + "autoload": { + "psr-4": { + "mirzaev\\vk\\chat\\": "mirzaev/vk/chat/system" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "WTFPL" + ], + "authors": [ + { + "name": "Arsen Mirzaev Tatyano-Muradovich", + "email": "arsen@mirzaev.sexy", + "homepage": "https://mirzaev.sexy", + "role": "Programmer" + } + ], + "description": "Module for mirzaev/vk framework to build a chat robot", + "homepage": "https://git.mirzaev.sexy/mirzaev/vk-chat", + "keywords": [ + "chat", + "module", + "vk" + ], + "support": { + "email": "arsen@mirzaev.sexy", + "issues": "https://git.mirzaev.sexy/mirzaev/vk-chat/issues", + "wiki": "https://git.mirzaev.sexy/mirzaev/vk-chat/wiki" + }, + "funding": [ + { + "url": "https://fund.mirzaev.sexy", + "type": "funding" + } + ], + "time": "2022-11-07T13:01:09+00:00" + }, + { + "name": "monolog/monolog", + "version": "1.x-dev", + "source": { + "type": "git", + "url": "https://github.com/Seldaek/monolog.git", + "reference": "904713c5929655dc9b97288b69cfeedad610c9a1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/904713c5929655dc9b97288b69cfeedad610c9a1", + "reference": "904713c5929655dc9b97288b69cfeedad610c9a1", + "shasum": "" + }, + "require": { + "php": ">=5.3.0", + "psr/log": "~1.0" + }, + "provide": { + "psr/log-implementation": "1.0.0" + }, + "require-dev": { + "aws/aws-sdk-php": "^2.4.9 || ^3.0", + "doctrine/couchdb": "~1.0@dev", + "graylog2/gelf-php": "~1.0", + "php-amqplib/php-amqplib": "~2.4", + "php-console/php-console": "^3.1.3", + "phpstan/phpstan": "^0.12.59", + "phpunit/phpunit": "~4.5", + "ruflin/elastica": ">=0.90 <3.0", + "sentry/sentry": "^0.13", + "swiftmailer/swiftmailer": "^5.3|^6.0" + }, + "suggest": { + "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", + "doctrine/couchdb": "Allow sending log messages to a CouchDB server", + "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", + "ext-mongo": "Allow sending log messages to a MongoDB server", + "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", + "mongodb/mongodb": "Allow sending log messages to a MongoDB server via PHP Driver", + "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", + "php-console/php-console": "Allow sending log messages to Google Chrome", + "rollbar/rollbar": "Allow sending log messages to Rollbar", + "ruflin/elastica": "Allow sending log messages to an Elastic Search server", + "sentry/sentry": "Allow sending log messages to a Sentry server" + }, + "type": "library", + "autoload": { + "psr-4": { + "Monolog\\": "src/Monolog" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "Sends your logs to files, sockets, inboxes, databases and various web services", + "homepage": "http://github.com/Seldaek/monolog", + "keywords": [ + "log", + "logging", + "psr-3" + ], + "support": { + "issues": "https://github.com/Seldaek/monolog/issues", + "source": "https://github.com/Seldaek/monolog/tree/1.27.1" + }, + "funding": [ + { + "url": "https://github.com/Seldaek", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/monolog/monolog", + "type": "tidelift" + } + ], + "time": "2022-06-09T08:53:42+00:00" + }, + { + "name": "psr/http-client", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-client.git", + "reference": "22b2ef5687f43679481615605d7a15c557ce85b1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/22b2ef5687f43679481615605d7a15c557ce85b1", + "reference": "22b2ef5687f43679481615605d7a15c557ce85b1", + "shasum": "" + }, + "require": { + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" + }, + "default-branch": true, + "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": "https://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" + ], + "support": { + "source": "https://github.com/php-fig/http-client/tree/master" + }, + "time": "2020-09-19T09:12:31+00:00" + }, + { + "name": "psr/http-factory", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-factory.git", + "reference": "5a4f141ac2e5bc35e615134f127e1833158d2944" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-factory/zipball/5a4f141ac2e5bc35e615134f127e1833158d2944", + "reference": "5a4f141ac2e5bc35e615134f127e1833158d2944", + "shasum": "" + }, + "require": { + "php": ">=7.0.0", + "psr/http-message": "^1.0" + }, + "default-branch": true, + "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": "https://www.php-fig.org/" + } + ], + "description": "Common interfaces for PSR-7 HTTP message factories", + "keywords": [ + "factory", + "http", + "message", + "psr", + "psr-17", + "psr-7", + "request", + "response" + ], + "support": { + "source": "https://github.com/php-fig/http-factory/tree/master" + }, + "time": "2022-07-14T07:21:53+00:00" + }, + { + "name": "psr/http-message", + "version": "dev-master", + "source": { + "type": "git", + "url": "https://github.com/php-fig/http-message.git", + "reference": "efd67d1dc14a7ef4fc4e518e7dee91c271d524e4" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/efd67d1dc14a7ef4fc4e518e7dee91c271d524e4", + "reference": "efd67d1dc14a7ef4fc4e518e7dee91c271d524e4", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "default-branch": true, + "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" + ], + "support": { + "source": "https://github.com/php-fig/http-message/tree/master" + }, + "time": "2019-08-29T13:16:46+00:00" + }, + { + "name": "psr/log", + "version": "1.1.4", + "source": { + "type": "git", + "url": "https://github.com/php-fig/log.git", + "reference": "d49695b909c3b7628b6289db5479a1c204601f11" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/log/zipball/d49695b909c3b7628b6289db5479a1c204601f11", + "reference": "d49695b909c3b7628b6289db5479a1c204601f11", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Log\\": "Psr/Log/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", + "keywords": [ + "log", + "psr", + "psr-3" + ], + "support": { + "source": "https://github.com/php-fig/log/tree/1.1.4" + }, + "time": "2021-05-03T11:20:27+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.", + "support": { + "issues": "https://github.com/ralouphie/getallheaders/issues", + "source": "https://github.com/ralouphie/getallheaders/tree/develop" + }, + "time": "2019-03-08T08:55:37+00:00" + }, + { + "name": "symfony/deprecation-contracts", + "version": "dev-main", + "source": { + "type": "git", + "url": "https://github.com/symfony/deprecation-contracts.git", + "reference": "4912000e79dc2d6df029d35d8755be1ed79b6691" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/4912000e79dc2d6df029d35d8755be1ed79b6691", + "reference": "4912000e79dc2d6df029d35d8755be1ed79b6691", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "default-branch": true, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.2-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "files": [ + "function.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A generic function and convention to trigger deprecation notices", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/deprecation-contracts/tree/main" + }, + "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": "2022-05-20T13:56:22+00:00" + }, + { + "name": "triagens/arangodb", + "version": "3.9.x-dev", + "source": { + "type": "git", + "url": "https://github.com/arangodb/arangodb-php.git", + "reference": "21c460dbbd75eb5c066f9abcc3a9adf4487d6e48" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/arangodb/arangodb-php/zipball/21c460dbbd75eb5c066f9abcc3a9adf4487d6e48", + "reference": "21c460dbbd75eb5c066f9abcc3a9adf4487d6e48", + "shasum": "" + }, + "require": { + "php": ">=5.6.0" + }, + "type": "library", + "autoload": { + "psr-0": { + "ArangoDBClient": "lib/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "Jan Steemann", + "homepage": "https://github.com/arangodb/arangodb-php", + "role": "Developer" + }, + { + "name": "Frank Mayer", + "homepage": "https://github.com/arangodb/arangodb-php", + "role": "Developer" + }, + { + "name": "Contributors", + "homepage": "https://github.com/arangodb/arangodb-php/graphs/contributors" + } + ], + "description": "ArangoDB PHP client", + "homepage": "https://github.com/arangodb/arangodb-php", + "keywords": [ + "Arango", + "ArangoDb", + "database", + "distributed", + "document store", + "graph database", + "multi-model", + "nosql" + ], + "support": { + "issues": "https://github.com/arangodb/arangodb-php/issues", + "source": "https://github.com/arangodb/arangodb-php/tree/3.9" + }, + "time": "2022-10-21T15:30:53+00:00" + } + ], + "packages-dev": [], + "aliases": [], + "minimum-stability": "dev", + "stability-flags": [], + "prefer-stable": false, + "prefer-lowest": false, + "platform": { + "php": "^8.1" + }, + "platform-dev": [], + "plugin-api-version": "2.3.0" +} diff --git a/mirzaev/vk/robot/bobby/system/public/.gitignore b/mirzaev/vk/robot/bobby/system/public/.gitignore new file mode 100644 index 0000000..4276bf9 --- /dev/null +++ b/mirzaev/vk/robot/bobby/system/public/.gitignore @@ -0,0 +1 @@ +index.php diff --git a/mirzaev/vk/robot/bobby/system/public/index.php.template b/mirzaev/vk/robot/bobby/system/public/index.php.template new file mode 100644 index 0000000..63c2a63 --- /dev/null +++ b/mirzaev/vk/robot/bobby/system/public/index.php.template @@ -0,0 +1,69 @@ +group('group id here')->key('group key here'); + +// Инициализация обработчика LongPoll API +$longpoll = new longpoll($robot); + +// Инициализация базы данных +$database = new database(new connection(require SYSTEM_PATH_ROOT . 'settings/arangodb.php')); + +// Очистка базы данных (тестирование) +$database->truncate(); + +// Инициализация модуля "чат-робот" +$chat = new chat; + +// Инициализация команды "ролевое действие" +$chat->pattern('/\*([A-я\w\s]+)\*/', new command(function (array $update, string $text) use ($robot) { + try { + // Удаление сообщения + $robot->message()->delete($update['object']['message']['conversation_message_id'], $update['object']['message']['peer_id']); + } catch (Exception $e) { + } + + // Инициализация данных отправителя + $sender = $robot->user()->get($update['object']['message']['from_id']); + + // Отправка ответа + $robot->message($update['object']['message']['peer_id'], "@id$sender->id ($sender->first_name) $text"); +})); + +$longpoll->handle(function (array $update) use ($robot, $database, $chat) { + // Обработка события + + // var_dump($update); + + // Сохранение события в базе данных + // $database->save($update); + + // Обработка команды + $chat->handle($update); +}); diff --git a/mirzaev/vk/robot/bobby/system/settings/.gitignore b/mirzaev/vk/robot/bobby/system/settings/.gitignore new file mode 100644 index 0000000..dac8cf6 --- /dev/null +++ b/mirzaev/vk/robot/bobby/system/settings/.gitignore @@ -0,0 +1 @@ +arangodb.php diff --git a/mirzaev/vk/robot/bobby/system/settings/arangodb.php.template b/mirzaev/vk/robot/bobby/system/settings/arangodb.php.template new file mode 100644 index 0000000..42c06d7 --- /dev/null +++ b/mirzaev/vk/robot/bobby/system/settings/arangodb.php.template @@ -0,0 +1,8 @@ + '', + 'database' => '', + 'name' => '', + 'password' => '' +];