https://developers.braintreepayments.com/ios+php/sdk/server/recurring-billing/create
result = Braintree_Subscription::create(array(
'paymentMethodToken' => 'the_token',
'planId' => 'silver_plan'
));
我的代码中是否是随机生成的字符串?还是别的什么?
答案 0 :(得分:2)
paymentMethodToken是客户信用卡使用的唯一标识符。使用存储的付款方式创建客户后,您可以使用返回的令牌将用户订阅到计划。这篇文章解释得很好:
https://developers.braintreepayments.com/ios+php/guides/recurring-billing