Assets Platform Developer

Assets Platform Developer

Rate this page:

Asset types

This resource represents asset types in Jira. Asset types are used to categorize assets. Use this resource to get, create, update, and delete assets in Jira.

Returns all asset types.

GET /rest/assetapi/asset/type

Fetches all available asset types. Only asset types with an appKey matching an installed asset management app will be returned. If no asset management apps are installed, falls back to returning all asset types.

Request

Query parameters
start

integer

The index of the first item to return in a page of results (page offset).

Default: 0, Format: int32
limit

integer

The maximum number of items to return per page. Note that this may be constrained by the Assets platform service.

Default: 50, Format: int32

Example

1
2
3
curl --request GET \
  --url '/rest/assetapi/asset/type' \
  --header 'Accept: application/json'

Responses

Returned if the request is successful. The response may be empty, if no results are found.

Content typeValue
application/json

assetTypes

Creates or updates an asset type.

PUT /rest/assetapi/asset/type

Creates a new asset type or updates an existing asset type. Note that updating an asset type will overwrite its properties with the properties defined in the request object.

Request

Body parameters
origin

origin

label

label

Example

1
2
3
4
5
6
7
8
9
10
11
12
13
curl --request PUT \
  --url '/rest/assetapi/asset/type' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data '{
  "origin": {
    "appKey": "com.myasset.app",
    "originId": "5-113-51143-2032"
  },
  "label": {
    "value": "MacBook Pro 15\" 2016"
  }
}'

Responses

Returned if the resource is updated.

Content typeValue
application/json

assetType

Deletes an asset type

DELETE /rest/assetapi/asset/type/{appKey}/{originId}

Request

Path parameters
appKey Required

string

The app key, which should be the Connect app key. This parameter is used to scope the originId.

originId Required

string

The identifier of an asset/asset type. This is the same identifier for the asset/asset type in its origin (external) system.

Example

1
2
curl --request DELETE \
  --url '/rest/assetapi/asset/type/{appKey}/{originId}'

Responses

Returned if the request is successful.

Rate this page: