我已创建并向客户发送了发票,然后我使用了检索发票进行检查。状态为SENT,但客户未收到邮件发票。这是我的代码:
$send = "curl -v -X 'POST' 'https://api.sandbox.paypal.com/v1/invoicing/invoices/INV2-DZF4-Y9AU-4L7U-ZF7W/send' -H 'Content-Type: application/json' -H 'Authorization: Bearer " . $access_token . "'";
exec($send, $sendResult);
$receive = "curl -v -X 'GET' 'https://api.sandbox.paypal.com/v1/invoicing/invoices/INV2-DZF4-Y9AU-4L7U-ZF7W' -H 'Authorization: Bearer " . $access_token . "'";
exec($receive, $receiveResult);
$receiveResultReponse = json_decode(implode(" ", $receiveResult));
print_r($receiveResultReponse);($receiveResultReponse);
回应:
stdClass Object
(
[id] => INV2-DZF4-Y9AU-4L7U-ZF7W
[number] => 0122
[status] => SENT
[merchant_info] => stdClass Object
(
...
[metadata] => stdClass Object
(
[created_date] => 2015-08-31 02:22:21 PDT
[first_sent_date] => 2015-08-31 02:22:22 PDT
[last_sent_date] => 2015-08-31 02:22:22 PDT
[payer_view_url] => https://www.sandbox.paypal.com/cgi_bin/webscr?cmd=_pay-inv&viewtype=altview&id=INV2-DZF4-Y9AU-4L7U-ZF7W
)
)
客户无法收到发票电子邮件。
答案 0 :(得分:3)
Sandbox不发送电子邮件......
电子邮件地址不一定是真实的电子邮件地址; Sandbox不会在Sandbox环境之外发送任何电子邮件。
参考:Creating Sandbox Test Accounts
你可以:
... H个