---
updatedAt: 2026-11-04T20:35:20.000Z
agentTools:
  projectIndex: https://cloud.docs.tamr.com/llms.txt
---

# update

Updates the data of a relationship to the given data.

Preview the results of this operation by setting the `dryRunbody` parameter to `true`.

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Relationships",
    "version": "v1alpha1"
  },
  "tags": [
    {
      "name": "tamr.api.v1alpha1.Relationships"
    }
  ],
  "paths": {
    "/api/v1alpha1/relationships/{relationshipId}": {
      "put": {
        "summary": "update",
        "description": "Updates the data of a relationship to the given data.",
        "operationId": "Relationships_UpdateRelationship",
        "responses": {
          "200": {
            "description": "A successful response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/tamr.api.v1alpha1.UpdateRelationshipResponse"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "name": "relationshipId",
            "description": "The identifier of the relationship to update.",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/tamr.api.v1alpha1.Relationships.UpdateRelationshipBody"
              }
            }
          },
          "required": true
        },
        "tags": [
          "tamr.api.v1alpha1.Relationships"
        ]
      }
    }
  },
  "x-readme": {
    "headers": [
      {
        "key": "X-API-KEY",
        "value": "example-api-key"
      }
    ]
  },
  "servers": [
    {
      "url": "https://api-examples.tamr.cloud"
    }
  ],
  "components": {
    "schemas": {
      "tamr.api.v1alpha1.Relationship": {
        "type": "object",
        "properties": {
          "relationshipId": {
            "type": "string",
            "description": "The identifier for the relationship."
          },
          "versionId": {
            "type": "string",
            "format": "int64",
            "description": "Output only. The current version of the relationship.",
            "readOnly": true
          },
          "createTime": {
            "type": "string",
            "format": "date-time",
            "description": "Output only. The time at which the relationship was created.",
            "readOnly": true
          },
          "updateTime": {
            "type": "string",
            "format": "date-time",
            "description": "Output only. The time at which the relationship was last updated.",
            "readOnly": true
          },
          "fromTableId": {
            "type": "string",
            "description": "The table of the originating record."
          },
          "fromRecordId": {
            "type": "string",
            "description": "The identifier of the originating record."
          },
          "toTableId": {
            "type": "string",
            "description": "The table of the terminating record."
          },
          "toRecordId": {
            "type": "string",
            "description": "The identifier of the terminating record."
          },
          "relationshipTypeId": {
            "type": "string",
            "description": "The identifier of the type of the relationship."
          },
          "details": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Additional details about the relationship."
          }
        }
      },
      "tamr.api.v1alpha1.Relationships.UpdateRelationshipBody": {
        "type": "object",
        "properties": {
          "fromTableId": {
            "type": "string",
            "description": "The table of the originating record."
          },
          "fromRecordId": {
            "type": "string",
            "description": "The identifier of the originating record."
          },
          "toTableId": {
            "type": "string",
            "description": "The table of the terminating record."
          },
          "toRecordId": {
            "type": "string",
            "description": "The identifier of the terminating record."
          },
          "relationshipTypeId": {
            "type": "string",
            "description": "The identifier of the type of the relationship."
          },
          "details": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Additional details about the relationship."
          },
          "expectedVersion": {
            "description": "The expected version of the relationship. If specified, operation is performed only if the current version of the relationship matches this.",
            "allOf": [
              {
                "$ref": "#/components/schemas/tamr.api.v1alpha1.VersionValidation"
              }
            ]
          },
          "fromRecordVersion": {
            "description": "The expected version of the from record of the relationship If specified, operation is performed only if the current version of the record matches this.",
            "allOf": [
              {
                "$ref": "#/components/schemas/tamr.api.v1alpha1.VersionValidation"
              }
            ]
          },
          "toRecordVersion": {
            "description": "The expected version of the to record of the relationship If specified, operation is performed only if the current version of the record matches this.",
            "allOf": [
              {
                "$ref": "#/components/schemas/tamr.api.v1alpha1.VersionValidation"
              }
            ]
          },
          "dryRun": {
            "type": "boolean",
            "description": "Optional. Run the same checks as the update, including the relationship type's hierarchy constraints and expected versions, and return the relationship as it would be updated, without updating it. A refusal returns the same status and ErrorInfo reason as the update. Fields only a write assigns are unset: version_id, create_time and update_time. Advisory: a concurrent write can land first, and the real write's check is final. Default is false."
          }
        },
        "required": [
          "fromTableId",
          "fromRecordId",
          "toTableId",
          "toRecordId",
          "relationshipTypeId"
        ]
      },
      "tamr.api.v1alpha1.UpdateRelationshipResponse": {
        "type": "object",
        "properties": {
          "relationship": {
            "description": "The updated relationship.",
            "allOf": [
              {
                "$ref": "#/components/schemas/tamr.api.v1alpha1.Relationship"
              }
            ]
          }
        }
      },
      "tamr.api.v1alpha1.VersionValidation": {
        "type": "object",
        "properties": {
          "versionId": {
            "type": "string",
            "format": "int64"
          }
        }
      }
    }
  }
}
```