Modify a Record

The various details of how to modify a record is explained in this section.

HTTP Method

PUT

Endpoint URL

See Endpoint.

Resource

/records/{repositoryName}

Request Parameters

Specify the following parameters:

Name Description Type Data Type
repositoryName Specify the repository name.

This is Mandatory.

path string
perspectiveName Specify the perspective name. query string
workItemId Specify the work item ID. query string

Request Model

Media Type: application/json.

Record to be modified record.productId and record.productIdExt are used to identify the original record. The attributes PRODUCTID and PRODUCTIDEXT values are used to update the records.

{  
   "process":false,
   "validate":false,
   "workItemId":"string",
   "perspectiveName":"string",
   "record":{  
      "productId":"string",
      "productIdExt":"string",
      "version":"string",
      "state":"string",
      "key":0,
      "attributes":[  
         {  
            "name":"string",
            "value":"string",
            "displayName":"string",
            "multivalues":[  
               {  

               }
            ],
            "type":0,
            "id":0,
            "multivalue":false
         }
      ],
      "repositoryName":"string",
      "relationship":{  
         "relationshipName":[  
            {  
               "relationshipAttributes":[  
                  {  
                     "name":"string",
                     "value":"string",
                     "displayName":"string",
                     "multivalues":[  
                        {  

                        }
                     ],
                     "type":0,
                     "id":0,
                     "multivalue":false
                  }
               ],
               "targetRecord":{  
                  "productId":"string",
                  "productIdExt":"string",
                  "version":"string",
                  "state":"string",
                  "key":0,
                  "attributes":[  
                     {  
                        "name":"string",
                        "value":"string",
                        "displayName":"string",
                        "multivalues":[  
                           {  

                           }
                        ],
                        "type":0,
                        "id":0,
                        "multivalue":false
                     }
                  ],
                  "repositoryName":"string",
                  "relationships":{  

                  },
                  "deleted":false
               }
            }
         ]
      },
      "deleted":false
   }
}

Response Model

The server sends response 200 OK with HTTP status code for each successfully completed request. The success response format is as follows:

{
  "responseMessages": [
    {
      "code": "string",
      "message": "string",
      "type": "string"
    }
  ],
  "records": [
    {
      "repositoryName": "string",
      "productId": "string",
      "productIdExt": "string",
      "productKeyId": "string",
      "responseAttributes": [
        {
          "attributeName": "string",
          "attributeDisplayName": "string",
          "values": [
            "string"
          ],
          "errorCode": "string",
          "errorMessage": "string",
          "errorType": "string"
        }
      ],
      "responseRelationships": [
        {
          "relationshipName": "string",
          "sourceRepositoryName": "string",
          "targetRepositoryName": "string",
          "recordId": "string",
          "recordIdExt": "string",
          "productKeyId": "string",
          "responseAttributes": [
            {
              "attributeName": "string",
              "attributeDisplayName": "string",
              "values": [
                "string"
              ],
              "errorCode": "string",
              "errorMessage": "string",
              "errorType": "string"
            }
          ]
        }
      ]
    }
  ],
  "success": true
}
Note: The response is displayed for validation error.

If response is unsuccessful, either of the following error code is displayed:

  • 400 Bad Request
  • 404 Not Found
  • 500 Internal Server Error

For error code response, see Error Handling .