intercom-php icon indicating copy to clipboard operation
intercom-php copied to clipboard

API Should not return 404 on input error

Open tarjei opened this issue 4 years ago • 0 comments

Version info

  • intercom-php version: 4.4
  • Intercom API version: 2.2
  • PHP version:7.4

Expected behavior

400 bad request

Actual behavior

404 not found

Steps to reproduce (as granular as possible, including screenshots where appropriate)

  1. $this->intercomClient is the intercom/intercom-php client.
  2. Given:
$this->intercomClient->post('contacts/merge', [
            'from' => $fromId,
            'to' => $toId,
        ]);

  1. I get: EXCEPTION: Not Found 404 Http\Client\Common\Exception\ClientErrorExceptionHeaders: {"Host":["api.intercom.io"],"Accept":["application/json"],"Content-Type":["application/json"],"User-Agent":["Intercom-PHP/4.4.0"],"Intercom-Version":["2.2"],"Authorization":["Bearer xxx"]} https://api.intercom.io/contacts/merge

Logs

tarjei avatar Sep 29 '20 06:09 tarjei