#pants_pagination-dotnet
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1217576954975227995
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
hi
Hi, if you're looking to list all charges made by a specific customer you can use the List All Charges API, https://docs.stripe.com/api/charges/list#list_charges-customer and pass in the customer id. Can you try this?
Yes, it would list all charges. However, there is a limit on how any charges would be returned on the response and you could use our auto-pagination function, https://docs.stripe.com/api/pagination/auto to pull all automatically.
you cant debug ListAutoPaging ?
I do not understand the follow up question here. Can you clarify?
if you try to watch the value it says Error = Cannot evaluate expression since the function evaluation requires all threads to run.
var charges = service.ListAutoPaging(options);
What language are you using? Can you share the entire code for this request?
c#
var options = new ChargeListOptions { };
var service = new ChargeService();
var charges = service.ListAutoPaging(options);
it shows in watch if using service.list
its ok i just to to add toList()
Ok, I am using Node and using the API reference it works for me.
yes its designed to work on a loop not get all
yeap!
sorry i cant get this date created working
im not sure if it needs some sort of child object
What about it does it not work?
created.gte
integer
Minimum value to filter by (inclusive)
well if i just add created = datetime its giving 0 results
var options = new ChargeListOptions { Created = DateTime.Now.ToUniversalTime().AddDays(-2) };
Are you passing in UTC timezone and have a customer created after that timeline?
yes theres a charge here
ch_3OtxbvJKY8YXH2zh1rrIU5hi
Can you share the request id where you're making this request to list these charges?
req_MaT2YktOrkTNxB
Taking a look
sending created = 1710193915
right looks like it doesnt allow datetime as per the intillicence in .net
this is ok:
var dateRange = new DateRangeOptions();
dateRange.GreaterThan = DateTime.Now.ToUniversalTime().AddDays(-2);
var options = new ChargeListOptions { Created = dateRange };
Asking someone else on my team who knows a bit more about .NET, thank you for your patience
well it works with that so i should be able to finish it now thanks
Glad you got it working!
thanks ๐