Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to convert confluence page data into CSV?

Varun P February 14, 2023

Hello Group,

We are working on a project and we want to explore converting confluence page data into a CSV file with Headers, Title, and Page ID as columns and S.No as rows. We tried exporting the page contents to JSON format and converting it into CSV format, but it didn't work properly because of the body.storage contains XHTML response and the python Json converter are not converting them into the format.

 Any help on this would be appreciated. Thanks

2 answers

1 vote
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 14, 2023

CSV is not a suitable storage format for Confluence data, so I have to ask the question of "why"?  What are you doing this for, what is the actual problem you are trying to solve by doing this?

As the format is useless for Confluence data, there's no way to export it.  The best you'll be able to do is to write an extract that reads pages over the REST interface, jams the resulting data into CSV and loses some of it.

Varun P February 14, 2023

We are creating an ML model that needs the confluence data as training inputs and we thought CSV is a better format to load this confluence data to the ML model. Please suggest what is the best way to load the confluence document data to the ML model, if you think that CSV is not a better option.

1 vote
Fabio Racobaldo _Herzum_
Community Champion
February 14, 2023

Hi @Varun P and welcome,

if you are on a server instance, you could retrieve those information using a query. On a cloud instance, you need to use rest API and write a script that perform that type of conversion.

Fabio

Varun P February 14, 2023

The storage.body data is in XHTML format. The generic python scripts are not able to properly convert the XHTML data to CSV or any other formats. Do we have any available XHTML converter to convert the Confluence storage.body data to any other formats?

Like Disha Patel likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events