Jump to content

SalesInvoices 500 error


 Share

Recommended Posts

Hi Matt,

The sales_invoices search param allows you to pass an alpha numeric string that allows you to find an invoice or invoices by invoice number, reference or contact name.

The response will return invoices matching your criteria. I'm not 100% clear on what you're trying to do with the show_payments_allocations but this attribute is very resource intensive and performs an inner join to the allocations table in the backend. If your search results result in a large list of invoices being returned the request will time out as the the gateway response time is only 28 seconds.

If you can clarify the use case for this we should be able to provide some help in making the requests more efficient.

Thanks

Mark

Link to comment
Share on other sites

We're searching here for an invoice by its invoice reference, so this should be returning either 1 or 0 results. I suppose it is possible that the inner join is causing the query to timeout at the API server, but we wouldn't expect this search to be returning more than a single result.

Link to comment
Share on other sites

Thanks for the info.

We're currently looking at the data and can confirm that the problem does not lie with the request. We've been unable to replicate the behaviour using the same params and business. 


The issue looks to be related to a backend issue. There are over 143 pages of requests logged for this business over the last 7 days so we'll ideally need the x-amzn-RequestId or the x-request-id. If you don't have either of those, could you provide the date/time of the response please?

Thanks

Mark

Link to comment
Share on other sites

  • 3 months later...
35 minutes ago, Team Paul said:

I am using  'https://api.accounting.sage.com/v3.1/sales_invoices' this endpoint to get all sales invoices list, But API is not getting all details. It is only returning 

collection in this format  {"id""XXXXXXXX"displayed_as""SI-",$path""/sales_invoices/586117de375711e8b45c025132dab352"}.

How can we get all data as suggested in the API guideline. 

 

Link to comment
Share on other sites

https://api.accounting.sage.com/v3.1/sales_invoices is the index request which tells you the number of records available and provides you with the id's of the sales_invoices should you require the detail of the transaction. 

The path that is returned by the index 
https://api.accounting.sage.com/v3.1/sales_invoices/586117de375711e8b45c025132dab352 will return the sales invoice details for the requested id.

What data do you require from the sales_invoice. If you can provide us with the scope of the integration and the requirements we will be able to suggest the most efficient ways of obtaining the data.

Thanks

Mark

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...