You are here

public function SendinblueApiV3::getUser in SendinBlue 7.2

Get user by email.

Parameters

string $email: An email address.

Return value

GetExtendedContactDetails An array of response code.

Overrides SendInBlueApiInterface::getUser

1 call to SendinblueApiV3::getUser()
SendinblueApiV3::createUpdateUser in includes/Api/SendinblueApiV3.php
Create and update user.

File

includes/Api/SendinblueApiV3.php, line 247

Class

SendinblueApiV3
Sendinblue REST client.

Code

public function getUser($email) {
  try {
    $contactInfo = $this->sibContactsApi
      ->getContactInfo($email);
    return new GetExtendedContactDetails(drupal_json_decode($contactInfo));
  } catch (Throwable $e) {
    return NULL;
  }
}