Skip to main content

Operations

An operation is an action that is executed against a single asset. For example, to delete an asset you must execute the Delete operation on the asset. To close or inactivate a Workitem, you must use the Inactivate Operation. When executing an operation a request must be made to the URL using the POST HTTP method.

How to Delete a Story Asset​

Post a request to this URL with an empty or 0 byte request.

~/rest-1.v1/Data/Story/1021?op=Delete

The XML Response will look something like this.

<Asset href="/VersionOne/rest-1.v1/Data/Story/1021/2365" id="Story:1021:2365" />

Notice the returned "Asset" node which indicates the asset was properly updated or in this example deleted. The "href" attribute can be used to retrieve the asset in its deleted state. When deleting an asset from the system, the asset is simply marked as deleted. Future current info queries will automatically excluded deleted assets from results.

A deleted asset can be restored with the Undelete operation.

How to Undelete a Story Asset​

Post a request to this URL with an empty or 0 byte request.

~/rest-1.v1/Data/Story/1021?op=Undelete

The XML Response will look something like this.

<Asset href="/VersionOne/rest-1.v1/Data/Story/1021/2369" id="Story:1021:2369" />

The asset is restored and appears in current info queries again. Undelete can be refused where restoring would conflict with current state; for example, a workitem whose parent has since been closed cannot be undeleted.

How to Close a Story Asset​

Post a request to this URL with an empty or 0 byte request.

~/rest-1.v1/Data/Story/1022?op=Inactivate

The XML Response will look something like this.

<Asset href="/VersionOne/rest-1.v1/Data/Story/1022/2367" id="Story:1022:2367" />

The returned "Asset" node indicates the asset was properly updated. You can use the "href" attribute to retrieve the Story asset and see the AssetState attribute changed. The AssetState attribute is the internal state of an asset.

How to Reopen a Story Asset​

Post a request to this URL with an empty or 0 byte request.

~/rest-1.v1/Data/Story/1022?op=Reactivate

The XML Response will look something like this.

<Asset href="/VersionOne/rest-1.v1/Data/Story/1022/2368" id="Story:1022:2368" />

The returned "Asset" node indicates the asset was properly updated. You can use the "href" attribute to retrieve the Story asset and see the AssetState attribute changed.

How to Activate a Timebox Asset​

Post a request to this URL with an empty or 0 byte request.

~/rest-1.v1/Data/Timebox/2011?op=Activate

The XML Response will look something like this.

<Asset href="/VersionOne/rest-1.v1/Data/Timebox/2011/2254" id="Timebox:2011:2254" />

The returned "Asset" node indicates the asset was properly updated.