RelationshipREST Resource

REST interface for entity relationships.

POST /v2/relationship

Create a new relationship between entities.

Request Body
media type data type
application/json AtlasRelationship (JSON)
application/json;charset=UTF-8 (custom)
Response Body
media type data type description
application/json AtlasRelationship (JSON)
application/json;charset=UTF-8 (custom)

Example

Request
POST /v2/relationship
Content-Type: application/json
Accept: application/json

                
{
  "blockedPropagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "createTime" : 12345,
  "createdBy" : "...",
  "end1" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "end2" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "guid" : "...",
  "homeId" : "...",
  "label" : "...",
  "propagateTags" : "NONE",
  "propagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "provenanceType" : 12345,
  "status" : "ACTIVE",
  "updateTime" : 12345,
  "updatedBy" : "...",
  "version" : 12345,
  "attributes" : {
    "property1" : { },
    "property2" : { }
  },
  "typeName" : "..."
}
                
              
Response
HTTP/1.1 201 Created
Content-Type: application/json

                
{
  "blockedPropagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "createTime" : 12345,
  "createdBy" : "...",
  "end1" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "end2" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "guid" : "...",
  "homeId" : "...",
  "label" : "...",
  "propagateTags" : "TWO_TO_ONE",
  "propagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "provenanceType" : 12345,
  "status" : "DELETED",
  "updateTime" : 12345,
  "updatedBy" : "...",
  "version" : 12345,
  "attributes" : {
    "property1" : { },
    "property2" : { }
  },
  "typeName" : "..."
}
                
              

PUT /v2/relationship

Update an existing relationship between entities.

Request Body
media type data type
application/json AtlasRelationship (JSON)
application/json;charset=UTF-8 (custom)
Response Body
media type data type description
application/json AtlasRelationship (JSON)
application/json;charset=UTF-8 (custom)

Example

Request
PUT /v2/relationship
Content-Type: application/json
Accept: application/json

                
{
  "blockedPropagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "createTime" : 12345,
  "createdBy" : "...",
  "end1" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "end2" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "guid" : "...",
  "homeId" : "...",
  "label" : "...",
  "propagateTags" : "NONE",
  "propagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "provenanceType" : 12345,
  "status" : "DELETED",
  "updateTime" : 12345,
  "updatedBy" : "...",
  "version" : 12345,
  "attributes" : {
    "property1" : { },
    "property2" : { }
  },
  "typeName" : "..."
}
                
              
Response
HTTP/1.1 204 No Content
Content-Type: application/json

                
{
  "blockedPropagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "ACTIVE",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "createTime" : 12345,
  "createdBy" : "...",
  "end1" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "end2" : {
    "guid" : "...",
    "typeName" : "...",
    "uniqueAttributes" : {
      "property1" : { },
      "property2" : { }
    }
  },
  "guid" : "...",
  "homeId" : "...",
  "label" : "...",
  "propagateTags" : "BOTH",
  "propagatedClassifications" : [ {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }, {
    "entityGuid" : "...",
    "entityStatus" : "DELETED",
    "propagate" : true,
    "removePropagationsOnEntityDelete" : true,
    "validityPeriods" : [ {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    }, {
      "endTime" : "...",
      "startTime" : "...",
      "timeZone" : "..."
    } ],
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  } ],
  "provenanceType" : 12345,
  "status" : "DELETED",
  "updateTime" : 12345,
  "updatedBy" : "...",
  "version" : 12345,
  "attributes" : {
    "property1" : { },
    "property2" : { }
  },
  "typeName" : "..."
}
                
              

DELETE /v2/relationship/guid/{guid}

Delete a relationship between entities using guid.

Request Parameters
name type description
guid path

Example

Request
DELETE /v2/relationship/guid/{guid}
Content-Type: application/json

                
...
                
              
Response
HTTP/1.1 204 No Content

              

GET /v2/relationship/guid/{guid}

Get relationship information between entities using guid.

Request Parameters
name type description default constraints
guid path    
extendedInfo query false boolean
Response Body
media type data type description
application/json AtlasRelationshipWithExtInfo (JSON)
application/json;charset=UTF-8 (custom)

Example

Request
GET /v2/relationship/guid/{guid}
Content-Type: application/json
Accept: application/json

                
...
                
              
Response
HTTP/1.1 200 OK
Content-Type: application/json

                
{
  "referredEntities" : {
    "property1" : {
      "classificationNames" : [ "...", "..." ],
      "classifications" : [ {
        "entityGuid" : "...",
        "entityStatus" : "DELETED",
        "propagate" : true,
        "removePropagationsOnEntityDelete" : true,
        "validityPeriods" : [ { }, { } ],
        "attributes" : {
          "property1" : { },
          "property2" : { }
        },
        "typeName" : "..."
      }, {
        "entityGuid" : "...",
        "entityStatus" : "ACTIVE",
        "propagate" : true,
        "removePropagationsOnEntityDelete" : true,
        "validityPeriods" : [ { }, { } ],
        "attributes" : {
          "property1" : { },
          "property2" : { }
        },
        "typeName" : "..."
      } ],
      "displayText" : "...",
      "guid" : "...",
      "meaningNames" : [ "...", "..." ],
      "meanings" : [ {
        "confidence" : 12345,
        "createdBy" : "...",
        "description" : "...",
        "displayText" : "...",
        "expression" : "...",
        "relationGuid" : "...",
        "source" : "...",
        "status" : "IMPORTED",
        "steward" : "...",
        "termGuid" : "..."
      }, {
        "confidence" : 12345,
        "createdBy" : "...",
        "description" : "...",
        "displayText" : "...",
        "expression" : "...",
        "relationGuid" : "...",
        "source" : "...",
        "status" : "OTHER",
        "steward" : "...",
        "termGuid" : "..."
      } ],
      "status" : "ACTIVE",
      "attributes" : {
        "property1" : { },
        "property2" : { }
      },
      "typeName" : "..."
    },
    "property2" : {
      "classificationNames" : [ "...", "..." ],
      "classifications" : [ {
        "entityGuid" : "...",
        "entityStatus" : "ACTIVE",
        "propagate" : true,
        "removePropagationsOnEntityDelete" : true,
        "validityPeriods" : [ { }, { } ],
        "attributes" : {
          "property1" : { },
          "property2" : { }
        },
        "typeName" : "..."
      }, {
        "entityGuid" : "...",
        "entityStatus" : "ACTIVE",
        "propagate" : true,
        "removePropagationsOnEntityDelete" : true,
        "validityPeriods" : [ { }, { } ],
        "attributes" : {
          "property1" : { },
          "property2" : { }
        },
        "typeName" : "..."
      } ],
      "displayText" : "...",
      "guid" : "...",
      "meaningNames" : [ "...", "..." ],
      "meanings" : [ {
        "confidence" : 12345,
        "createdBy" : "...",
        "description" : "...",
        "displayText" : "...",
        "expression" : "...",
        "relationGuid" : "...",
        "source" : "...",
        "status" : "PROPOSED",
        "steward" : "...",
        "termGuid" : "..."
      }, {
        "confidence" : 12345,
        "createdBy" : "...",
        "description" : "...",
        "displayText" : "...",
        "expression" : "...",
        "relationGuid" : "...",
        "source" : "...",
        "status" : "VALIDATED",
        "steward" : "...",
        "termGuid" : "..."
      } ],
      "status" : "DELETED",
      "attributes" : {
        "property1" : { },
        "property2" : { }
      },
      "typeName" : "..."
    }
  },
  "relationship" : {
    "blockedPropagatedClassifications" : [ {
      "entityGuid" : "...",
      "entityStatus" : "ACTIVE",
      "propagate" : true,
      "removePropagationsOnEntityDelete" : true,
      "validityPeriods" : [ { }, { } ],
      "attributes" : {
        "property1" : { },
        "property2" : { }
      },
      "typeName" : "..."
    }, {
      "entityGuid" : "...",
      "entityStatus" : "ACTIVE",
      "propagate" : true,
      "removePropagationsOnEntityDelete" : true,
      "validityPeriods" : [ { }, { } ],
      "attributes" : {
        "property1" : { },
        "property2" : { }
      },
      "typeName" : "..."
    } ],
    "createTime" : 12345,
    "createdBy" : "...",
    "end1" : {
      "guid" : "...",
      "typeName" : "...",
      "uniqueAttributes" : {
        "property1" : { },
        "property2" : { }
      }
    },
    "end2" : {
      "guid" : "...",
      "typeName" : "...",
      "uniqueAttributes" : {
        "property1" : { },
        "property2" : { }
      }
    },
    "guid" : "...",
    "homeId" : "...",
    "label" : "...",
    "propagateTags" : "BOTH",
    "propagatedClassifications" : [ {
      "entityGuid" : "...",
      "entityStatus" : "ACTIVE",
      "propagate" : true,
      "removePropagationsOnEntityDelete" : true,
      "validityPeriods" : [ { }, { } ],
      "attributes" : {
        "property1" : { },
        "property2" : { }
      },
      "typeName" : "..."
    }, {
      "entityGuid" : "...",
      "entityStatus" : "DELETED",
      "propagate" : true,
      "removePropagationsOnEntityDelete" : true,
      "validityPeriods" : [ { }, { } ],
      "attributes" : {
        "property1" : { },
        "property2" : { }
      },
      "typeName" : "..."
    } ],
    "provenanceType" : 12345,
    "status" : "DELETED",
    "updateTime" : 12345,
    "updatedBy" : "...",
    "version" : 12345,
    "attributes" : {
      "property1" : { },
      "property2" : { }
    },
    "typeName" : "..."
  }
}