code: public function xml()
  	{
  		$this->validate();
  
  		$s = $this->template;
  		$s = str_replace('{{language}}', 'eng', $s);
  		$s = str_replace('{{main}}', $this->success ? $this->template_success : $this->template_failure, $s);
  		if ($this->success) {
  			$s = str_replace('{{id}}', $this->id, $s);
  			$s = str_replace('{{dateDue}}', $this->formatDateTime($this->dateDue), $s);
  		} else {
  			$s = str_replace('{{error}}', $this->error, $s);
  			$s = str_replace('{{errorDetails}}', $this->errorDetails, $s);
  		}
  		return $s;
  	}
docs: Return a XML representation of the request