public function getByEmail(string $emailAddress): AccountType
    {
        $response = $this->client->request(
            'GET',
            // $emailAddress must not be urlencoded
            $this->client->getConfig('base_uri') . '/accounts/' . $emailAddress . '/'
        );

        $json = json_decode($response->getBody());

        return (new AccountType)->fromJson($json);
    }
public function getByEmail(string $emailAddress): AccountType
    {
        $response = $this->client->request(
            'GET',
            // $emailAddress must not be urlencoded
            $this->client->getConfig('base_uri') . '/accounts/' . $emailAddress . '/'
        );

        $json = json_decode($response->getBody());

        return (new AccountType)->fromJson($json);
    }
public function getByEmail ( string $ emailAddress ) : AccountType { $ response = $ this -> client -> request ( 'GET' , // $emailAddress must not be urlencoded $ this -> client -> getConfig ( 'base_uri' ) . '/accounts/' . $ emailAddress . '/' ) ; $ json = json_decode ( $ response -> getBody ( ) ) ; return ( new AccountType ) -> fromJson ( $ json ) ; }
Get AccountType instance by email address

Requires admin permissions

@param string $emailAddress Email address

@return AccountType
@throws \Exception
@throws \GuzzleHttp\Exception\GuzzleException
Get AccountType instance by email address