-
Notifications
You must be signed in to change notification settings - Fork 145
Description
I am trying to install intercom's php library. after installing it via composer I am getting following error.
Parse error: syntax error, unexpected 'function' (T_FUNCTION), expecting identifier (T_STRING) or \ (T_NS_SEPARATOR) in /home/drill/public_html/beta/vendor/intercom/intercom-php/src/IntercomClient.php on line 7
so I went to IntercomClient.php and I replace line
use function GuzzleHttp\Psr7\stream_for;
with line
use GuzzleHttp\Psr7\stream_for;
after that I got following error
Fatal error: Uncaught exception 'GuzzleHttp\Exception\ClientException' with message 'Client error: GET https://api.intercom.io/users resulted in a 401 Unauthorized response: {"type":"error.list","request_id":"apb4trdidr4ei616jmm0","errors":[{"code":"token_unauthorized","message":"Not authorize (truncated...) ' in /home/mikemydrillbook/public_html/beta/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:111 Stack trace: #0 /home/mikemydrillbook/public_html/beta/vendor/guzzlehttp/guzzle/src/Middleware.php(65): GuzzleHttp\Exception\RequestException::create(Object(GuzzleHttp\Psr7\Request), Object(GuzzleHttp\Psr7\Response)) #1 /home/mikemydrillbook/public_html/beta/vendor/guzzlehttp/promises/src/Promise.php(203): GuzzleHttp\Middleware::GuzzleHttp{closure}(Object(GuzzleHttp\Psr7\Response)) #2 /home/mikemydrillbook/public_html/beta/vendor/guzzlehttp/promises/src/Promise.php(156): GuzzleHttp\Promise\Promise::callHandler(1, Object(GuzzleHttp\Psr7\Response), Array) #3 /home/mikemydrillbook/public_html/beta/vendor/guzzl in /home/drill/public_html/beta/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php on line 111
Version info
- intercom-php version: Latest as of 1 jan 2017
- PHP version: 5.5.30
Expected behavior
Actual behavior
Steps to reproduce (as granular as possible, including screenshots where appropriate)
- I installed intercom PHP api via composer here is the link https://github.com/intercom/intercom-php
- I followed exactly what is mentioned in the above link and got these above 2 errors