Perform read and write operations on a Confluence page from a Jira Plugin

Hello all,

Would appreciate some advice.

A user creates a Jira ticket. From this ticket they perform a transition that calls a custom plugin. We will call the transition “Create Calendar”.

The plug in should access a confluence page called Calendar Template, make a copy of it, and save it. I will leave it it that for now.

What is the best way to go about this?

Edit: Previous problem fixed, but still require a hint.

  1. Configure workflow transition to have a post function, that generates an event.
  2. Plugin listens to said event.
  3. Plugin uses Confluence Server REST API to get the content required.
  4. Plugin saves the data, with or What is the best way to store data in a Jira Plugin? - #3 by t.neychev