REST API


You can create baselines through REST API.

The format for a Baseline Create call is as follows:

HTTP POST  

<confluence_server>/plugins/servlet/baselinecreateservlet?space-key=<space_key>&baseline-name=<baseline_name>&baseline-keyword=<baseline_keyword>&date-field=<baseline_date>&selectAllPages=<select_all_pages>&fullySelectedPages=<fully_selected_pages>&partiallySelectedPages=<partially_selected_pages>


ParamDescriptionSample
confluence_serverThe full URL for your Confluence Serverhttp://192.168.0.71:6110/confluence611
space_keyThe key of the Confluence document space for which the baseline will be createdABC
baseline_nameThe name of the baseline that will be createdMy New Baseline
baseline_keyword

(Optional) The keyword for the baseline. Any string works.

!!! Leave empty if you are not sure how to use this.


baseline_dateThe date and exact time for the baseline12.09.2018 11:08:12
select_all_pages

Whether all pages in the space will be included in the baseline

Possible values:

  • true
  • false
  • true
  • false
fully_selected_pages

Used if "select_all_pages" is false

A comma separated list of page ID's. The pages in this list will be included in the baseline WITH all their subpages.

  • 12345
  • 12345,13564
partially_selected_pages

Used if "select_all_pages" is false

A comma separated list of page ID's. The pages in this list will be included in the baseline WITHOUT their subpages.

  • 12345
  • 12345,13564


Sample Requests:

(HTTP POST) 

http://192.168.0.71:6110/confluence611/plugins/servlet/baselinecreateservlet?space-key=ds&baseline-name=My New Baseline 1&baseline-keyword=&date-field=12.09.2018 11:08:12&selectAllPages=true

http://192.168.0.71:6110/confluence611/plugins/servlet/baselinecreateservlet?space-key=ds&baseline-name=My New Baseline 2&baseline-keyword=&date-field=12.09.2018 11:08:12&selectAllPages=false&fullySelectedPages=65540,66534&partiallySelectedPages=63578,34527