MangoPay/Libraries/AuthenticationHelper.php
public function GetHttpHeaderBasicKey()
    {
        if (is_null($this->_root->Config->ClientId) || strlen($this->_root->Config->ClientId) == 0) {
            throw new Exception('MangoPayApi.Config.ClientId is not set.');
        }
        
        if (is_null($this->_root->Config->ClientPassword) || strlen($this->_root->Config->ClientPassword) == 0) {
            throw new Exception('MangoPayApi.Config.ClientPassword is not set.');
        }
        
        $signature = $this->_root->Config->ClientId . ':' . $this->_root->Config->ClientPassword;
        return base64_encode($signature);
    }
public function GetHttpHeaderBasicKey()
    {
        if (is_null($this->_root->Config->ClientId) || strlen($this->_root->Config->ClientId) == 0) {
            throw new Exception('MangoPayApi.Config.ClientId is not set.');
        }
        
        if (is_null($this->_root->Config->ClientPassword) || strlen($this->_root->Config->ClientPassword) == 0) {
            throw new Exception('MangoPayApi.Config.ClientPassword is not set.');
        }
        
        $signature = $this->_root->Config->ClientId . ':' . $this->_root->Config->ClientPassword;
        return base64_encode($signature);
    }
public function GetHttpHeaderBasicKey ( ) { if ( is_null ( $ this -> _root -> Config -> ClientId ) || strlen ( $ this -> _root -> Config -> ClientId ) == 0 ) { throw new Exception ( 'MangoPayApi.Config.ClientId is not set.' ) ; } if ( is_null ( $ this -> _root -> Config -> ClientPassword ) || strlen ( $ this -> _root -> Config -> ClientPassword ) == 0 ) { throw new Exception ( 'MangoPayApi.Config.ClientPassword is not set.' ) ; } $ signature = $ this -> _root -> Config -> ClientId . ':' . $ this -> _root -> Config -> ClientPassword ; return base64_encode ( $ signature ) ; }
Get basic key for HTTP header
@return string
@throws \MangoPay\Libraries\Exception If MangoPay_ClientId or MangoPay_ClientPassword is not defined
Get basic key for HTTP header