【发布时间】:2021-07-11 11:54:23
【问题描述】:
我在 Laravel 中使用 paypal API,一切正常。我只需要找到获取用户电子邮件地址和姓名的方法。
$payment = Payment::get($payment_id, $this->_api_context);
$execution = new PaymentExecution();
$execution->setPayerId( $request->query('PayerID') );
$result = $payment->execute($execution, $this->_api_context);
if ($result->getState() == 'approved') {
// I should get the info about the payer here
}
【问题讨论】: