Good day i have this api where it can do bulk orders, and inside the documents it said that "There is a 2000 limit but we might decide to change it to a lower / higher value at any given time depending if we find this value is too high or too low with time. " so the limitations include a maximum of 2000 orders per import and only one import can run at a time per project, how can i do the 2000 bulk orders with just one call api? is it possible is there i way i can do this on a loop? i am using a structure and its json
Thanks so much mam and sirs!
please check this solution. it is working with the csv given by you.
you can create a list of structure and after that you can serialize in json. can you share more detail like payload json you are trying to sending to api.
I checked your oml file but there is no api implementation that I can follow so please provide more detail so it will be easy to help
https://docs.voucherify.io/reference/import-orders here it is sir
I use the sample json given in api documentation and created a structure using this json
created a server action with a local vairable ListOfOrders
and appeding values in the ListOfOrders and after that I can use JSONSerialize and send this to the api. It should work.
may ia ask sir why u dont use for loop for one by one?
i got this error sir
you can not directly pass the json to the request. It is a structure you need to convert your json to the structure and that pass that structure to the request.
You can use loop to append data in to the list and pass that list to the api
I provided the oml file you can check the implementation there.
i follow what you did and it worked! the problem sir is the one that is passing only in the api is just the start? how can i do it until the first and last!??
you need to append element in the list using loop can you share your oml file so I can see and implement solution accordingly ?
you need to loop your data source and append element in the list using listappend server action.
then pass that list variable to the api.
Is your data source is csv ? or you fetching data from database ?
after i use csv to json i send into API
this is it sir my OML
No need to loop now as you are using list you can directly pass it to the your api.
can you share your csv file as well ?
cant share the csv file sir. i apologize. can i know i don need for loop?
Do not share actual csv share a dummy csv so I can confirm and send you solution oml
Do not need loop as it is already a list
IVE tried this sir but this doesnt work sir. :(( still stuck in here
Please share dummy csv
here it is sir
thank you so much for this sir might try this later.
Hi @jesu verso,
Could you please share your API structure.
I have updated your oml. Please check.
my api structure is the link you can check it sir its import order
I implemented api using sample data please check the oml. Hope this will help you.
thanksmight try this sir. sorry for late reply
no worries. hope my solution works for you.
HI, Please refer this https://www.outsystems.com/forums/discussion/101481/json-to-structure-to-api/Thanks,Sahana