我在尝试实现Neteller的REST时遇到了问题。我已经在商人帐户中创建了我的应用程序(我的网站没有SSL证书),我的网站有一个静态IP,它被添加到Neteller的允许的IP列表中,但是由于某些原因,我总是从他们那里得到一个无效的响应。
这是我的密码:
$username = 'XXXXXXXXXXXXXXXX';
$password = 'XXxxxxxXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
$curl = curl_init();
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_URL, "https://api.neteller.com/v1/oauth2/token?grant_type=client_credentials");
curl_setopt($curl, CURLOPT_USERPWD, "$username:$password");
curl_setopt($curl, CURLOPT_HTTPHEADER, array("Content-Type:application/json", "Cache-Control:no-cache"));
curl_setopt($curl, CURLOPT_POSTFIELDS, array("scope"=>"default"));
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
$serverOutput = curl_exec($curl);
$info = curl_getinfo($curl);
echo $serverOutput; // null response有人能帮我解决这个问题吗?
https://stackoverflow.com/questions/35354410
复制相似问题