Skip to content

Update an Asset Type

Reference:

Field Description
Name (Name ID) Unique name identifier. It must contain only lowercase alphanumeric characters. The characters ., _ and - are allowed to separate words instead of a space BUT can not be at the beginning or end of the name.
Title (Display Name) The display name to show on the Kelvin UI. It can contain any characters, including spaces.

Update Asset Type

Updating an Asset Type closely mirrors its creation process. However, the name of the Asset Type is non-editable. To modify the name, you must create a new Asset Type.

Asset Types can be managed from the Administration section of the UI.

Do not get confused with the Asset management in the Operations section which is designed for the Production Engineers.

To start, go to the Assets in the Administration section of the left side bar and then click on the Asset Types tab.

To edit an Asset Type, click on the pencil icon on the right hand side of of an Asset Type row;

Then a popup will be displayed where you can edit the Title of an Asset Type.

API cURL Example
1
2
3
4
5
6
7
8
curl -X "POST" \
"https://<url.kelvin.ai>/api/v4/assets/types/doc_demo_asset_type/update" \
-H "Authorization: Bearer <Your Current Token>" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
        "title": "Updated Demo Asset Type"
    }'

You will get a response similar to this;

API cURL Example Response
1
2
3
4
5
6
{
    "name": "doc_demo_asset_type",
    "title": "Updated Demo Asset Type",
    "created": "2025-01-23T08:53:28.650245Z",
    "updated": "2025-01-23T08:53:29.891434Z"
}
API Client (Python) Example
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
from kelvin.api.client import Client

# Login
client = Client(url="https://<url.kelvin.ai>", username="<your_username>")
client.login(password="<your_password>")

# Update Asset Type
response = client.asset.update_asset_type(
    asset_type_name="doc_demo_asset_type", 
    data={
        "title": "Updated Demo Asset Type"
    }
)

print(response)

You will get a response similar to this;

API Client (Python) Example Response
1
created=datetime.datetime(2024, 5, 23, 8, 52, 7, 803281, tzinfo=datetime.timezone.utc) name='doc_demo_asset_type' title='Updated Demo Asset Type' updated=datetime.datetime(2024, 5, 23, 8, 52, 14, 881512, tzinfo=datetime.timezone.utc)