Knowledge Base

 View Only

Edit an Item Using the Jama REST API

By John Schroeder posted 10-08-2015 17:21


This article describes how to use the Jama REST API to edit an item. This is very common in custom integrations, but can crop up in other applications as well.

Before You Begin
This process assumes you have an application which can interact with the Jama REST API, and which can consume, edit, and generate JSON data. It also assumes that the edits you’re making are on items in a live project. If no users or other applications will be interacting with the items you’ll be editing, the ‘Lock’ and ‘Unlock’ steps can be omitted.  

The basic workflow for editing an item in Jama using the REST API involves five (5) steps. Before you begin, you need the item’s ID so you can lock it. Since you intend to edit the item, you’ve probably already gotten its ID and stored it somewhere.

CAUTION: PUT’s definition requires that it create or replace a resource. Any data not supplied in the PUT request will not exist in the item after the PUT completes -- even if it existed before. The specification of PUT can be found at

1. Lock the item to be edited, otherwise there’s a small chance that someone can make changes to the item while you are editing it.  If someone else has locked the item, your attempt to lock it may fail.

2. Now GET the item you just locked.

Copy and paste the “data” object into the PUT request and edit the “description” field.

4. When you make the put request the entire resource is replaced with this new data object.  

Now unlock the item and the edit is complete.



03-30-2016 16:13


There are some situations where you need to remove certain read-only fields from the PUT request body.  In most cases the system can tell that the data is the same and lets the PUT go through, but sometimes (usually with dates) it can't tell that they're the same.  I've seen this most often with test runs.

PUT will not affect the relationships between the item you're updating and other items.


03-30-2016 03:28

Thanks Grant. I found that I must enter the old fields as well and not only the field I want to change ("Name", for example), else PUT deletes them.

03-24-2016 19:31

I found that in order to do a PUT for an item, I had to remove the createdDate and modifiedDate fields (from GET results) as I was getting the same error.

Also, when using the bare minimum data for a PUT, I had to include the parent item which the PUT document says is optional...

"location": {"parent": {"item": 31037711}},
"fields": {"name": "Updated from REST"}
This worked!

03-17-2016 13:11

1. I got an error saying: "You cannot set read-only fields. fields: createdDate, modifiedDate"
2. Just to be sure- PUT will not (!) delete upstream/downstream relationships of the item we want to edit, right?

Thanks John.