36
Views
16
Comments
Solved
CSV to JSON specific position
Question
Application Type
Reactive
Service Studio Version
11.55.7 (Build 63962)
Platform Version
11.33.0 (Build 44426)

I have a bulk data inside of CSV to send to an API. the problem is that the api cant accept the data through CSV file type but it must be JSON format first. but the problem i encounter is that i have a specific structure of json that i need to position so that API may read and accept it. is there a way i can position the data that i need to a specific position or variable of the API? thanks!


2024-11-07 03-28-42
Stuart Harris
Champion
Solution

Hi Jesu,


Could you clarify what you mean by "I need to position so the API may ready and accept it"? This will help us answer your question.

Normally, a JSON API does not require a specific order of attributes; if that is your requirement. However, maybe your API has special requirements.

To convert CSV onto JSON, I would normally consume the API in OutSystems which will create a structure that matches the API.

Then define a structure for the CSV, and import all the rows. There is a forge component that will help you with this.

Then either use ListAppendAll, or a For loop, to add all the records to the list of records in the API request structure.

I hope this helps.

Kind regards,

Stuart

UserImage.jpg
jesu verso

SORRY for the confusion sir "I need to position so the API may ready and accept it"?  what i mean by this is that i need to position csv data like id -> API ID like that

UserImage.jpg
jesu verso

what is the  forge  sir? i might need that thnak you!

2022-12-30 07-28-09
Navneet Garg


https://www.outsystems.com/forge/

forge is where you can found useful component which you can use in outsystems.

Forge is a repository of reusable, open code modules, connectors, UI components, and business solutions to help speed up your OutSystems apps delivery time.


UserImage.jpg
jesu verso

i mean what is the forge that is need thnaks!

2022-12-30 07-28-09
Navneet Garg

There are lots of csv forge component available search as you needed and read document 

I am sharing one of the component. you can check it.
https://www.outsystems.com/forge/component-overview/10780/csv-to-json-o11


UserImage.jpg
jesu verso
2022-12-30 07-28-09
Navneet Garg

can you please provide more detail that what is not working ? or can you please share csv file so I can try that at my end.


2025-12-03 17-22-41
Lavanya Kamalaguru
Solution

Hi @jesu verso,

I have implemented the logic based on your requirement. Please check out my oml.

Thanks,

Lavanya Kamalaguru

CVS_TO_Json.oml
UserImage.jpg
jesu verso

what forge did u use on this sir

2024-11-07 03-28-42
Stuart Harris
Champion
Solution

Hi Jesu,


Could you clarify what you mean by "I need to position so the API may ready and accept it"? This will help us answer your question.

Normally, a JSON API does not require a specific order of attributes; if that is your requirement. However, maybe your API has special requirements.

To convert CSV onto JSON, I would normally consume the API in OutSystems which will create a structure that matches the API.

Then define a structure for the CSV, and import all the rows. There is a forge component that will help you with this.

Then either use ListAppendAll, or a For loop, to add all the records to the list of records in the API request structure.

I hope this helps.

Kind regards,

Stuart

UserImage.jpg
jesu verso

SORRY for the confusion sir "I need to position so the API may ready and accept it"?  what i mean by this is that i need to position csv data like id -> API ID like that

UserImage.jpg
jesu verso

what is the  forge  sir? i might need that thnak you!

2022-12-30 07-28-09
Navneet Garg


https://www.outsystems.com/forge/

forge is where you can found useful component which you can use in outsystems.

Forge is a repository of reusable, open code modules, connectors, UI components, and business solutions to help speed up your OutSystems apps delivery time.


UserImage.jpg
jesu verso

i mean what is the forge that is need thnaks!

2022-12-30 07-28-09
Navneet Garg

There are lots of csv forge component available search as you needed and read document 

I am sharing one of the component. you can check it.
https://www.outsystems.com/forge/component-overview/10780/csv-to-json-o11


UserImage.jpg
jesu verso
2022-12-30 07-28-09
Navneet Garg

can you please provide more detail that what is not working ? or can you please share csv file so I can try that at my end.


2022-12-30 07-28-09
Navneet Garg

You can create structure from your json and use that structure to create csv file.

Can you please share more detail so it will easy to help you.

If possible share oml file.


UserImage.jpg
jesu verso

CSV -> JSON -> API this is the part

2022-12-30 07-28-09
Navneet Garg

I found another one. You can use the Forge component 

https://www.outsystems.com/forge/component-overview/636/csvutil

to convert a CSV to an OutSystems record list, which you then can serialize to a JSON structure. 

UserImage.jpg
jesu verso

thanks for this!

2025-12-03 17-22-41
Lavanya Kamalaguru
Solution

Hi @jesu verso,

I have implemented the logic based on your requirement. Please check out my oml.

Thanks,

Lavanya Kamalaguru

CVS_TO_Json.oml
UserImage.jpg
jesu verso

what forge did u use on this sir

2025-12-03 17-22-41
Lavanya Kamalaguru

@jesu verso Try this CSV to XLSX. I am using the same and that is working.

Thanks,

Lavanya

UserImage.jpg
jesu verso

thank you sir

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.