API provides not all invoices

Version v5.13.24

Environment ISP Hosted

Checklist

  • Can you replicate the issue on our v5 demo site https://demo.invoiceninja.com or Invoice Ninja? >> Didn’t test. I have another test installation without that issue
  • Have you searched existing issues? >> Yes
  • Have you inspected the logs in storage/logs/laravel.log for any errors? >> I did. But I don’t find any related messages. But a a lot of information about deprecated functions.

Describe the bug

I want to do autoamtion tasks with n8n. Goal is to receive a webhook about a completed payment from Paypal, searchf or the invoice, get the customer information and creat an expense in invoice ninja.
When I pull a list of all invoices vie API the result only has 44 entries.

Request URL: https://example.com/api/v1/invoices?per_page=25

Result:
“meta”: {
“pagination”: {
“total”: 44,
“count”: 25,
“per_page”: 25,
“current_page”: 1,
“total_pages”: 2,
“links”: {
“next”: “https://example.com/api/v1/invoices?page=2
}
}
}

But in general I have much more invoices. I tried filters to include/exclude open/payed/archived invoices with no change.

Steps To Reproduce

Call the mentioned API URL

Expected Behavior

Provide a list of all invoices. With pagination. It should show the correct number of invoices.

Additional context

Screenshots

As you can see there should ba at least 96 invoices

Logs

The weird thing is, that even by trying to sort descending by number (i.e.) I only get the same 44 results that dont include the invoice I search for.

Hi,

The web app also uses the API, I suggest using the browser console to compare API requests.

Do you mean to use the same URL with my Browser?

I used n8n for the API calls and Postman.

I suggest using the browser console to see what API requests the web is making to compare to your requests.

OK, just call the same URL in Browser?

Sorry, I’m not sure what you mean.

Do you know how to view the browser console?

Yes, that’s what I mean.