Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Data Type

Attribute Name

Default Value

Remarks

String

projectIdString

"-1"

"-1" will be all other project

If not, it will be the projectId of project

String

covererId

The coverer username if reassignMode is set to "coverer"

Set to "-" for do not re-assign issue

String

covererAvatar

The small avatar img of coverer which is used to populate in one time rule table

String

covererDisplayName

The coverer full name which is used to populate in one time rule table

String

projectInfo

The project name and key which are configured

String

reassignMode

Can use "reassign", for re-assigning issue

Can use "unassign", for unassigning issue ( the (info) the option is only available if JIRA allow unassign issue)

info

Can use "same", for do not re-assign issue

String

oneTimeMessage

Message to be added into comment should the user is OOO

String

startDateString

String of the out of office start date format ("yyyy-MM-dd HH:mm")

String

endDateString

String of the out of office end date format ("yyyy-MM-dd HH:mm")

String

creatorAvatar

The small avatar img of rule creator which is used to populate in one time rule table

String

creatorDisplayName

The creator full name which is used to populate in one time rule table

String

assigneeId

The ooo user's username

String

assigneeAvatar

The ooo user's avatar

String

assigneeDisplayName

The ooo user's full name

int

oneTimeId

0

The id of the one time rule for update and delete rule

boolean

byAdmin

false

if the rule is configured by admin

boolean

byTeam

false

if the rule is configured by team

...

Expand
titleGetting all your own One-Time Rule (GET)

Method

Status
colourBlue
titleGET

URL

/rest/ooo/1.0/onetimerule

Data

Return an array of OneTimeRule object
See above inner class section on data transaction

Example

Code Block
[
    {
        "projectIdString": "10001",
        "covererId": "",
        "covererAvatar": "",
        "covererDisplayName": "",
        "projectInfo": "Akeles [AKELES]",
        "reassignMode": "unassign",
        "startDateString": "2018-10-11 00:00",
        "endDateString": "2018-10-18 23:59",
        "oneTimeId": 5,
        "byAdmin": false,
        "byTeam": false,
        "creatorAvatar": "http://192.168.9.150:8080/secure/useravatar?size=xsmall&avatarId=10337",
        "creatorDisplayName": "John",
        "assigneeId": "",
        "assigneeAvatar": "",
        "assigneeDisplayName": ""
    }
]

Remarks

Info

Does not allow you to search based on assigneeId. It will return all the one time rule configured for the current logged in user

Expand
titleCreate a new One-Time Rule (POST)

Method

Status
colourGreen
titlePOST

URL

/rest/ooo/1.0/onetimerule

Parameters

Required the following field

Code Block
{
    "assigneeId": "1000222",
    "projectIdString": "2",
    "reassignMode": "unassign",
    "covererId": "",
    "startDateString": "2018-09-14 12:00",
    "endDateString": "2018-09-20 12:00"
}

Response

Status
colourGreen
titleSTATUS 200
(tick)

  • Successful creation of new one time rule

Status
colourRed
titleSTATUS 401
(error)

  • UNAUTHORIZED - Not logged in or do not have administrator access

Status
colourRed
titleSTATUS 406
 (error)

  • NOT_ACCEPTABLE - Error when validating data or invalid user

Remarks

Will perform validateUser() and validateOneTimeRule()

User - Check if user is admin if byAdmin is set to true
OneTimeRule - Check for data format and mandatory data required

Expand
titleEdit an existing One-Time Rule (PUT)

Method

Status
colourGreen
titlePUT

URL

/rest/ooo/1.0/onetimerule

Parameters

Required the following field

Code Block
{
    "oneTimeId": "2",
    "assigneeId": "1000222",
    "projectIdString": "2",
    "reassignMode": "coverer",
    "covererId": "1000232",
    "startDateString": "2018-09-14 12:00",
    "endDateString": "2018-09-20 12:00"
}

Response

Status
colourGreen
titleSTATUS 200
(tick)

  • Successful editing of existing one time rule

Status
colourRed
titleSTATUS 401
(error)

  • UNAUTHORIZED - Not logged in or do not have administrator access

Status
colourRed
titleSTATUS 406
 (error)

  • NOT_ACCEPTABLE - Error when validating data or invalid user

Remarks

Will perform validateUser() and validateOneTimeRule()

User - Check if user is admin if byAdmin is set to true
OneTimeRule - Check for data format and mandatory data required

Expand
titleDelete an existing One-Time Rule (DELETE)

Method

Status
colourYellow
titleDELETE

URL

/rest/ooo/1.0/onetimerule

Parameters

Required the following field

Code Block
{
    "oneTimeId": "2"
}

Response

Status
colourGreen
titleSTATUS 200
(tick)

  • Successful deleting of existing one time rule

Status
colourRed
titleSTATUS 401
(error)

  • UNAUTHORIZED - Not logged in or do not have administrator access

Status
colourRed
titleSTATUS 406
 (error)

  • NOT_ACCEPTABLE - Error when validating data or invalid user

Remarks

Will perform validateUser() and validateOneTimeRule()

User - Check if user is admin if byAdmin is set to true
OneTimeRule - Check for data format and mandatory data required

Expand
titleGet all Rule configured by adminstrator

Method

Status
colourBlue
titleGET

URL

/rest/ooo/1.0/onetimerule/admin

Data

Code Block
[
  {
    "projectIdString": "2",
    "covererId": "1000232",
    "covererAvatar": "",
    "covererDisplayName": "ABCDE",
    "projectInfo": "All other projects",
    "reassignMode": "coverer",
    "oneTimeMessage": "abcde is OOO",
    "startDateString": "2018-09-14 12:00",
    "endDateString": "2018-09-20 12:00"
    "oneTimeId": 2,
    "byAdmin": true,
    "byTeam": false,
    "creatorAvatar": "",
    "creatorDisplayName": "Administrator",
    "assigneeId": "1000222",
    "assigneeAvatar": "",
    "assigneeDisplayName": "FGHIJ",
    "sdInternalComment": false,
    "doNotRespondToPublic": false
  }
]

Remarks

Return an array of OneTimeRule

See above inner class section on data transaction

Info

Same as getting all of your own one time rule just that this is all rules created by admin.