/**
  * @param ClientInterface $client
  * @param GiropayBankstatusRequest $giropayRequest
  * @return RequestInterface
  */
 protected function buildBankstatusRequest(ClientInterface $client, GiropayBankstatusRequest $giropayRequest)
 {
     $requestArray = array();
     $requestArray['merchantId'] = $this->getMerchantId();
     $requestArray['projectId'] = $this->getProjectId();
     if ($giropayRequest->getBic() == "") {
         throw new InvalidArgumentException("Field bic is required");
     }
     $requestArray['bic'] = $giropayRequest->getBic();
     //this works because the hash list in PHP has a sort order (we get the values out in the order we added them)
     $sortedValuesString = implode('', array_values($requestArray));
     $requestArray['hash'] = $this->getHMACMD5Hash($this->getSecret(), $sortedValuesString);
     $request = $client->createRequest("POST", "https://payment.girosolution.de/girocheckout/api/v2/giropay/bankstatus", ['body' => $requestArray]);
     return $request;
 }