Push and Pull Filters and Dashboards via REST-API (for Developers)

Call REST-API

POST /rest/cwx-ppf/latest/push

or

POST /rest/cwx-ppf/latest/pull

These calls require authentication (see documentation of Jira's REST API on how to authenticate).

Configuration Parameters

ParameterDescriptionExample (JSON)
users
User name
 {
    "users": [ "alice", "bob" ],
	...
 }
groups
Group name
 {
    "groups": [ "jira-core-users", "customers" ],
	...
 }
filters
Filter ID
 {
    "filters": [ 10600 ],
	...
 }
dashboards
Dashboard ID
 {
    "dashboards": [ 11000, 11100 ],
	...
 }

You have to specify either users or groups.You also have to specify either filters or dashboards.

Example

curl -X POST -H "Content-Type: application/json" --data '{ "users": ["alice"], "filters": [ 10500 ] }' http://localhost:8080/rest/cwx-ppf/latest/push

Responses

HTTP ResponseDescription
Status 403The authenticated user does not have admin permissions or the add-on is not licensed.
Status 400

The request is not valid (for instance, no users and no groups, or no filters and no dashboards specified).

Status 200The request was processed successfully.

If the HTTP response is Status 200, the Push and Pull Favorites add-on provides the following response fields:

Field NamePossible ResultsDescription
success
true/falsesuccess will be true if the request could be processed completely without errors.
messages
Textmessages contains additional information.

Example

Response: Status 200

{
    "success": false,
    "messages": [ "Could not find user with name bob" ]
}