original_string: public function connect()
  	{
  		$request  = $this->sendRequest($this->baseUrl."/auth", array('username' => $this->login, 'password' => $this->password), 2);
  
  		$response = json_decode($request['body'], true);
  		if (array_key_exists('error', $response))
  		{
  			throw new \Exception('Erreur '.$response['code'].' : '.$response['error']);
  		} else {
  			$this->token = $response['token'];
  			$this->saveToken();
  		}
  	}
code: public function connect()
  	{
  		$request  = $this->sendRequest($this->baseUrl."/auth", array('username' => $this->login, 'password' => $this->password), 2);
  
  		$response = json_decode($request['body'], true);
  		if (array_key_exists('error', $response))
  		{
  			throw new \Exception('Erreur '.$response['code'].' : '.$response['error']);
  		} else {
  			$this->token = $response['token'];
  			$this->saveToken();
  		}
  	}
code_tokens: public function connect ( ) { $ request = $ this -> sendRequest ( $ this -> baseUrl . "/auth" , array ( 'username' => $ this -> login , 'password' => $ this -> password ) , 2 ) ; $ response = json_decode ( $ request [ 'body' ] , true ) ; if ( array_key_exists ( 'error' , $ response ) ) { throw new \ Exception ( 'Erreur ' . $ response [ 'code' ] . ' : ' . $ response [ 'error' ] ) ; } else { $ this -> token = $ response [ 'token' ] ; $ this -> saveToken ( ) ; } }
docstring: Connect to the T411 website to save the token key
docstring_tokens: Connect to the T411 website to save the token key