skip to Main Content

I want to integrate a telegram API in PHP.
I refereed following link
https://github.com/funcoding/TelegramPHPBot/blob/master/README.md
I installed composer on my machine but i am not able to generate
vendor/autoload.php file.
I am new to this. can anyone give me solution.

2

Answers


  1. After creating the composer.json file run composer install command to install the dependencies. This will create a vendor folder where you can find autoload.php file.

    Login or Signup to reply.
  2. Just follow below steps for install Telegram API:

    1. Download master.zip file. Extract zip file into your local wamp
      server.
    2. Open your cmd and then go to your wamp directory using cd wamp and cd www.
    3. Then go to your Telegram API directory using cd Telegram API
    4. Then run composer install command from command prompt
    5. Now you can see vendor folder in your Telegram API directory after finish installation.

    No need to edit composer.json file.

    See below screenshot

    enter image description here


    Composer.json code

    {
        "name": "curiouscoder/telegram-php-bot",
        "description": "Telegram Bot API written in PHP",
        "keywords": ["telegram-bot", "telegram", "bot", "api"],
        "type": "library",
        "require": {
          "php": ">=5.4",
          "guzzlehttp/guzzle": "5.3.0"
        },
        "require-dev": {
        },
        "autoload": {
            "psr-4": {
                "CuriousCoder\TelegramBot\": "src"
            }
        },
        "license": "MIT",
        "authors": [
            {
                "name": "Vinay Kumar",
                "email": "[email protected]",
            "role": "Developer"
            }
        ],
        "minimum-stability": "dev"
    }
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search