/** * @param string $imageServiceEndpoint */ public function __construct($imageServiceEndpoint) { $json = file_get_contents(__DIR__ . "/../Resources/config/service.json"); $guzzleCommandClient = new GuzzleCommandClient($json); $guzzleCommandClient->setBaseUrl($imageServiceEndpoint); $this->setGuzzleCommandClient($guzzleCommandClient); }
/** * Initialises the client based on the MWS access data provided * adds listeners for requests to add global parameters and sign the request * * @param string $mwsEndpoint the mws endpoint to use, depends on your marketplace_id * @param string $awsAccessKeyId your aws access key id * @param string $signatureMethod the signature method to use * @param int $signatureVersion the signature version to use * @param string $secretKey your mws secret key */ public function __construct($mwsEndpoint, $awsAccessKeyId, $signatureMethod, $signatureVersion, $secretKey) { $this->awsAccessKeyId = $awsAccessKeyId; $this->signatureMethod = $signatureMethod; $this->signatureVersion = $signatureVersion; $this->secretKey = $secretKey; $this->mwsEndpoint = $mwsEndpoint; $json = file_get_contents(__DIR__ . "/../Resources/config/service.json"); parent::__construct($json); parent::setBaseUrl($mwsEndpoint); }
/** * @param string $baseUrl */ public function setBaseUrl($baseUrl, $handler = NULL) { parent::setBaseUrl($baseUrl, $handler); }