【发布时间】:2016-11-22 06:38:55
【问题描述】:
我创建了一个数据库 customers.txt,其中保存了我在 Stripe 中创建的所有客户。现在我想列出所有的客户。这是我在 php 中列出客户的代码。
$e= \Stripe\Customer::all(array(
'limit' => 3
));
echo $e;
}
但是输出很奇怪:
有人可以帮我列出客户吗?
现在我得到了我的 JSON 并运行它:
$e=\Stripe\Customer::all(array(
"limit"=>10
));
$customers=json_decode($e,true);
var_dump($customers);
我得到的只是 NULL 响应!
【问题讨论】:
-
source 和 email 不是列表客户 api 的有效参数,stripe.com/docs/api#list_customers
-
@MatthewArkin 我编辑了帖子。
-
所以 $e->data 是一个客户数组,$e->data[0] 是一个客户对象。
标签: php database list stripe-payments