我Stripe
用作支付网关。现在有个大问题困扰着我。
我使用下面的代码来创建订阅:
<?php
require_once('lib/Stripe.php');
Stripe::setApiKey(API_KEY);
$token = $_POST['stripeToken'];
$customer = Stripe_Customer::create(array(
"card" => $token,
"plan" => $_POST['plan'],
"email" => "fakeuser@gmail.com",
));
这很好用,但我无法从中获取Charge ID
,$customer
并且我发现无法Stripe API
获取它。
创建订阅时如何获取?我真的需要Charge ID
。