1

I have a composer.json with content:

{
  "require":{
    "paypal/rest-api-sdk-php": "*"
  }
}

On trying to install the composer by below command composer install,

I'm getting this error message:

Your requirements could not be resolved to an installable set of packages.

The complete error log:

Problem 1
- paypal/rest-api-sdk-php v1.7.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.7.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.6.4 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.6.3 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.6.2 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.6.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.6.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.5.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.5.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.4.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.3.2 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.3.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.3.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.2.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.2.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.1.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.1.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v1.0.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.9.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.6 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.5 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.4 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.3 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.2 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.8.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.7.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.7.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.6.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.16.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.16.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.15.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.15.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.14.2 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.14.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.14.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.13.2 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.13.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.13.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.12.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.11.1 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.11.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php v0.10.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php V0.5.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.9.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.8.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.7.4 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.7.3 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.7.2 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.11.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- paypal/rest-api-sdk-php 1.10.0 requires ext-curl * -> the requested PHP extension curl is missing from your system.
- Installation request for paypal/rest-api-sdk-php * -> satisfiable by paypal/rest-api-sdk-php[1.10.0, 1.11.0, 1.7.2, 1.7.3, 1.7.4, 1.8.0, 1.9.0, V0.5.0, v0.10.0, v0.11.0, v0.11.1, v0.12.0, v0.13.0, v0.13.1, v0.13.2, v0.14.0, v0.14.1, v0.14.2, v0.15.0, v0.15.1, v0.16.0, v0.16.1, v0.6.0, v0.7.0, v0.7.1, v0.8.0, v0.8.1, v0.8.2, v0.8.3, v0.8.4, v0.8.5, v0.8.6, v0.9.0, v1.0.0, v1.1.0, v1.1.1, v1.2.0, v1.2.1, v1.3.0, v1.3.1, v1.3.2, v1.4.0, v1.5.0, v1.5.1, v1.6.0, v1.6.1, v1.6.2, v1.6.3, v1.6.4, v1.7.0, v1.7.1].

To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.0/cli/php.ini
- /etc/php/7.0/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.0/cli/conf.d/10-opcache.ini
- /etc/php/7.0/cli/conf.d/10-pdo.ini
- /etc/php/7.0/cli/conf.d/20-calendar.ini
- /etc/php/7.0/cli/conf.d/20-ctype.ini
- /etc/php/7.0/cli/conf.d/20-exif.ini
- /etc/php/7.0/cli/conf.d/20-fileinfo.ini
- /etc/php/7.0/cli/conf.d/20-ftp.ini
- /etc/php/7.0/cli/conf.d/20-gettext.ini
- /etc/php/7.0/cli/conf.d/20-iconv.ini
- /etc/php/7.0/cli/conf.d/20-json.ini
- /etc/php/7.0/cli/conf.d/20-mysqli.ini
- /etc/php/7.0/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.0/cli/conf.d/20-phar.ini
- /etc/php/7.0/cli/conf.d/20-posix.ini
- /etc/php/7.0/cli/conf.d/20-readline.ini
- /etc/php/7.0/cli/conf.d/20-shmop.ini
- /etc/php/7.0/cli/conf.d/20-sockets.ini
- /etc/php/7.0/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.0/cli/conf.d/20-sysvsem.ini
- /etc/php/7.0/cli/conf.d/20-sysvshm.ini
- /etc/php/7.0/cli/conf.d/20-tokenizer.ini

You can also run php --ini inside terminal to see which files are used by PHP in CLI mode.

I'm new to this. What am I missing here?

halfer
  • 19,824
  • 17
  • 99
  • 186
  • 1
    "the requested PHP extension curl is missing from your system" - [You need to install this extension.](http://stackoverflow.com/questions/33775897/how-do-i-install-the-ext-curl-extension-with-php-7) – samiles May 15 '17 at 14:08
  • How did you get on with the below assistance, Santhosh? – halfer Jun 19 '17 at 13:25
  • @halfer It fixed the issue. – Santhosh Dhaipule Chandrakanth Jun 19 '17 at 14:00
  • Lovely. It is customary, and a basic politeness, to respond to it in some fashion. You may upvote, comment or accept. In general, accepting an answer is the most appropriate in this case. To do so, click on the tick icon adjacent to the answer, so that it turns green. This gives the helper some points for their kindness, and marks the question as resolved. – halfer Jun 19 '17 at 14:18

1 Answers1

7

In your php installation curl extension is missing. You need to install it by running:

sudo apt-get install php7.0-curl

And after that this error should disappear.