Create Space or Page from SQL data?

Is it possible to create a Space or Page from SQL data? Would be willing to use any available plugins. Ideally, an addition of a row in SQL would trigger the creation of the Space or Page. Would anyone be willing to point me in the right direction?

1 answer

1 accepted

Confluence Command Line Interface has a runFromSql that can do actions based on an SQL query. Actions like storePage or addSpace. That provides a base automation enablement, but there are lots of things to consider. Do you have control over the table columns or does a column have an insert timestamp? What about if a row is updated? Triggering from the database could be possible, but it is more likely you would drive the automation from timed queries of the database. You need some sort of job scheduler - my favorite is Bamboo :). If you use Bamboo for this type of thing, then there is CLI Plugin for Bamboo to make it easier. Or you can do some other scripting.

Bob, thank you for the quick response. Your plugins are a big inspiration for this question and make me feel like what I am trying to achieve is possible. We do have control over the table columns and I believe the column has an insert timestamp. If a row is updated I would probably have to create another "update" script that goes and updates the Space or Page. If I was to trigger from the database, are there any of your plugins that I would be able to call from an MSSQL job? Most of them seem to be called from within Confluence, but I have a very limited understanding of it all. I had not heard of Bamboo, so thank you for that. It seems a bit complicated for what I would use it for, but it looks like you may be able to create something simple without too much trouble.

If you have any other suggestions I would love to hear them. Either way, looks like I have quite a bit of reading and testing to do!

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Feb 06, 2019 in Confluence

Try out the new editing experience

Hi team, I’m Avinoam, a product manager on Confluence Cloud, and today I’m really excited to let the Community know that all customers can now try out the new editing experience and see some of the ...

1,030 views 51 8
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you