Lua helper function for confluence and jira
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Markus Bergholz 751d5a305e initial commit 3 years ago
README.md initial commit 3 years ago
atlassian.lua initial commit 3 years ago

README.md

Requirements

  • lua socket
  • lua cjson

Jira

Content

-- jira aufbau
 jira = {
   server = "http://username:password@jira.url/rest/api/2/issue/",
   jsontable = { fields = {
       project = { key = "ABC" },
       summary = "summary of this issue", -- fields[1]
       assignee = { name = "mustermann" },
       reporter = { name = "username" },
       description = "more detailed description", -- fields[2]
       issuetype = { name = "TASK" }
     }
   },
   debug = 0
 }

Usage:

require "atlassian"
jid = openissue(jira)

Confluence

Content

-- confluence aufbau
confluence = {
  server = "http://username:password@confluence.url/rest/api/content/",
  jsontable = {
      type = "page",
      title = "New Page Title",
      space = { key = "ABC"},
      body = { storage = { value = "Content of this page", representation = "storage" } },
    },
  debug = 0
  }

Usage:

require "atlassian"
pageid = newpage(confluence)