public function testGetCustomerAuthKeyWithValidEmail()
 {
     $request = $this->getRandomAddCustomerRequest();
     $this->apiClient->addCustomer($request);
     $request = new GetCustomerAuthKeyRequest(['email' => $request->getEmail()]);
     $response = $this->apiClient->getCustomerAuthKey($request);
     $this->assertNotEmpty($response->getAuthUrl());
 }
Esempio n. 2
0
 /**
  * @param \Solaris\Requests\GetCustomerAuthKeyRequest $request
  *
  * @return \Solaris\Responses\GetCustomerAuthKeyResponse
  */
 public function getCustomerAuthKey(GetCustomerAuthKeyRequest $request)
 {
     $data = ['MODULE' => 'Customer', 'COMMAND' => 'getAuthKey', 'email' => $request->getEmail()];
     $payload = new Payload($this->request($data));
     return new GetCustomerAuthKeyResponse($payload);
 }