/** * The class is instantiated with the 'SenderID' and password issued to the * claiming charity by HMRC. Also we need to know whether messages for * this session are to be sent to the test or live environment * * @param $sender_id The govTalk Sender ID as provided by HMRC * @param $password The govTalk password as provided by HMRC * @param $route_uri The URI of the owner of the process generating this route entry. * @param $software_name The name of the software generating this route entry. * @param $software_version The version number of the software generating this route entry. * @param $test TRUE if in test mode, else (default) FALSE * @param $httpClient The Guzzle HTTP Client to use for connections to the endpoint - null for default * @param $messageLogLocation Where to log messages - null for no logging */ public function __construct($sender_id, $password, $route_uri, $software_name, $software_version, $test = false, ClientInterface $httpClient = null, $messageLogLocation = null) { $test = is_bool($test) ? $test : false; $endpoint = $this->getEndpoint($test); $this->setProductUri($route_uri); $this->setProductName($software_name); $this->setProductVersion($software_version); $this->setTestFlag($test); parent::__construct($endpoint, $sender_id, $password, $httpClient, $messageLogLocation); $this->setMessageAuthentication('clear'); }