According to the Stripe API docs, the default limit for requesting a list of customers is 10. That is likely why you are only ending up with 10 customers instead of your entire list.
As is the case with many such APIs, the documentation includes a parameter to enable pagination, starting_after
or ending_before
. You can read more about to Stripe's API here - I would recommend building up your API doc reading muscles since I've personally found them to be incredibly helpful when working with a project like this.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…