Solved

Get all results from GI rest API using "PUT"

  • 27 October 2023
  • 8 replies
  • 102 views

Userlevel 3
Badge

Hey everyone

 

hope everything is good 

 

I’m trying to get all results from GI using “PUT” Method but i get only 1 result instated of all results that i have 

 

 

 

But here is my GI that i have in Acumatica

 

 

icon

Best answer by Dmitrii Naumov 27 October 2023, 16:54

View original

8 replies

Userlevel 7
Badge +11

Hi @Driss 

Can you please share the endpoint URL and Request JSON?

Userlevel 7
Badge +5

@Driss  make sure your GI is mapped to the endpoint properly. 

That is the header is mapped to the TopLevel entity and the results are mapped separately to the detail level entity under the TopLevel entity.

Userlevel 3
Badge

@Dmitrii Naumov Hey Thanks for you answer i have created the endpoint like this 

 

 

Userlevel 7
Badge +5

@Driss looks good. 

You should then call the Put with $expand=Results

Userlevel 3
Badge

@Dmitrii Naumov  Hey Yeah i’ve added $expand=Results it throws 

"The given key was not present in the dictionary.",

 

I tried $expand=Result but still returning only one record 

 

 

Userlevel 7
Badge +5

@Driss it in fact will return one top level record, but inside there will be an array of Result records.

Userlevel 3
Badge

@Dmitrii Naumov Thanks, yeah it showing the array of result but it only one result on that array 

Userlevel 3
Badge

@Dmitrii Naumov  The issue is fixed i was populating results for Top-level and detail that was the issue i only populate that in the details that fixed the issue

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved