Versions Compared

Key

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

...

Generating API token

To use our API you need to generate an API token.

In order to generate a token, navigate to left side menu in the OKR for Jira app. Then choose ‘Settings', and ‘API’ menu item.

...

Image Removed

On the page click on the 'Generate new token’ button in the top right corner of the page.

Note

Copy the generated token somewhere safe. You will not be able to see it again.

...

Authenticating request with you API token

All requests to API should include API-Token header, which contains token generated in previous step.
If such header is not present, you will receive 400 Bad Request response.

API Administrator table

OKR for Jira provides a way to oversee all API tokens created within your organization.
Users with the API_ADMIN_TABLE_ACCESS permission have access to an expanded view on the API settings page.
The API administrator table allows you to see, rename or revoke any token within your organization.

...

All API fetch methods return the same JSON object structure. The data present depends on your query parameter.

Expand
titleExample response object:
Code Block
languagejson
{
	"okrs": [
		{
			"id": "5fda249d289742000406b3e4",
			"key": "O-2",
			"name": "Become more mature company",
			"description": "<p>This quarter we will be focusing on improving our performance.</p><p></p>",
			"parentObjectiveId": null,
			"ownerAccountId": "5c12ad9fd3af3b1ccfecbf55",
			"collaboratorAccountIds": [],
			"percentDone": 8.333333333333332,
			"created": "2020-12-16T15:15:41+0000",
			"startDate": "2021-01-01T00:00:00+0000",
			"deadline": "2021-03-31T23:59:59+0000",
			"labelIds": [],
			"teamIds": [],
			"krIds": [
				"605480b190c42b0003385170",
				"6061e921e2f4470003bc3210"
			],
			"childObjectiveIds": [
				"5fdb72c63d2cf000035ceb37",
				"60743135b347480003dc6a9c",
				"61f9367df9aa7f0e4024a6fe"
			],
			"latestUpdate": {
				"entityId": "5fda249d289742000406b3e4",
				"status": "ON_TRACK",
				"created": "2021-05-05T12:15:14+0000",
				"value": null,
				"description": ""
			},
			"periodAliasId": "602a6a2717378700039f342a",
			"weight": 0
		}
	],
	"krs": [
		{
			"id": "5fda249d289742000406b3e5",
			"key": "KR-2",
			"name": "adda",
			"description": null,
			"parentObjectiveId": "5fdb72c63d2cf000035ceb37",
			"issueIds": [
				"10003"
			],
			"ownerAccountId": "5c12ad9fd3af3b1ccfecbf55",
			"collaboratorAccountIds": [],
			"percentDone": 0.0,
			"created": "2020-12-16T15:15:41+0000",
			"startDate": "2021-01-05T00:00:00+0000",
			"deadline": "2021-03-28T00:59:59+0000",
			"labelIds": [],
			"teamIds": [],
			"periodAliasId": null,
			"latestUpdate": {
				"entityId": "61c993aaa0fd9b768a0fb47d",
				"status": "AT_RISK",
				"created": "2021-12-27T10:21:30+0000",
				"value": 0.0,
				"description": null
			},
			"unit": null,
			"currentProgressDefinition": {
				"type": "STANDARD",
				"startValue": 0.0,
				"desiredValue": 22.0,
				"jql": null
			},
			"weight": 1
		}
	],
	"teams": [
		{
			"id": "605df77c6e53750003068c7d",
			"name": "lets go!"
		}
	],
	"periods": [
		{
			"id": "602a6a2717378700039f342a",
			"name": "Q1 Y2021",
			"startDate": "2021-01-01T00:00:00+0000",
			"deadline": "2021-03-31T23:59:59+0000"
		}
	],
	"labels": [
		{
			"id": "611a18f6c385f85c13ac860a",
			"name": "Research"
		}
	]
}

...

Info

Translation in progress. Please refer to OKR API documentation