{"openapi":"3.0.4","info":{"title":"CluedIn REST API — Hierarchies","description":"Build and manage hierarchies and the global data model.","version":"v1"},"tags":[{"name":"GlobalDataModel"},{"name":"Hierarchies"}],"paths":{"/api/globaldatamodel":{"get":{"tags":["GlobalDataModel"],"summary":"Get global data model","parameters":[{"name":"edgeDirection","in":"query","schema":{"type":"string"},"description":"Optional edge direction filter."},{"name":"entityType","in":"query","schema":{"type":"string"},"description":"Optional entity type filter."},{"name":"integration","in":"query","schema":{"type":"string"},"description":"Optional integration filter."}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel"}}}}},"description":"Returns the relationship schema for entity types as a list of `From → To` paths. Optionally filtered by edge direction, entity type, and integration. The server only returns paths whose endpoints have data (or are temporal/entity-code paths), so the UI can render a graph that matches what is actually present in the organisation."}},"/api/v1/globaldatamodel":{"get":{"tags":["GlobalDataModel"],"summary":"Get global data model","parameters":[{"name":"edgeDirection","in":"query","schema":{"type":"string"},"description":"Optional edge direction filter."},{"name":"entityType","in":"query","schema":{"type":"string"},"description":"Optional entity type filter."},{"name":"integration","in":"query","schema":{"type":"string"},"description":"Optional integration filter."}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel"}}}}},"description":"Returns the relationship schema for entity types as a list of `From → To` paths. Optionally filtered by edge direction, entity type, and integration. The server only returns paths whose endpoints have data (or are temporal/entity-code paths), so the UI can render a graph that matches what is actually present in the organisation."}},"/api/hierarchies":{"get":{"tags":["Hierarchies"],"summary":"List hierarchies","parameters":[{"name":"searchName","in":"query","schema":{"type":"string"},"description":"Free-text search over hierarchy name."},{"name":"entityCode","in":"query","schema":{"type":"string"},"description":"Filter by entity code."},{"name":"filterStatus","in":"query","schema":{"type":"string"},"description":"Filter by hierarchy status (for example draft, published)."},{"name":"orderBy","in":"query","schema":{"type":"string"},"description":"Field to order by."},{"name":"orderAsc","in":"query","schema":{"type":"boolean"},"description":"Sort direction. Defaults to false (descending)."},{"name":"pageNumber","in":"query","schema":{"type":"integer","format":"int32","default":0},"description":"0-based page number. Defaults to 0."},{"name":"pageTake","in":"query","schema":{"type":"integer","format":"int32","default":20},"description":"Page size. Defaults to 20."}],"responses":{"200":{"description":"OK"}},"description":"Returns paged hierarchies for the organisation along with the total count. Filter by name, entity code, and status; sort by any supported field."},"post":{"tags":["Hierarchies"],"summary":"Create hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Creates one or more hierarchies. When `CreateWithTopLevelRoots` is true, the server discovers top-level roots from the supplied edge type/direction and uses them as project roots; when `CreateMultiProjects` is true, one hierarchy is created per root (subject to the organisation's multi-project limit — exceeding the limit returns 500 with an explanatory message)."},"put":{"tags":["Hierarchies"],"summary":"Update hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Updates an existing hierarchy. Returns 400 with validation details when the model is invalid or the id is empty, and 404 when the hierarchy cannot be found."}},"/api/v1/hierarchies":{"get":{"tags":["Hierarchies"],"summary":"List hierarchies","parameters":[{"name":"searchName","in":"query","schema":{"type":"string"},"description":"Free-text search over hierarchy name."},{"name":"entityCode","in":"query","schema":{"type":"string"},"description":"Filter by entity code."},{"name":"filterStatus","in":"query","schema":{"type":"string"},"description":"Filter by hierarchy status (for example draft, published)."},{"name":"orderBy","in":"query","schema":{"type":"string"},"description":"Field to order by."},{"name":"orderAsc","in":"query","schema":{"type":"boolean"},"description":"Sort direction. Defaults to false (descending)."},{"name":"pageNumber","in":"query","schema":{"type":"integer","format":"int32","default":0},"description":"0-based page number. Defaults to 0."},{"name":"pageTake","in":"query","schema":{"type":"integer","format":"int32","default":20},"description":"Page size. Defaults to 20."}],"responses":{"200":{"description":"OK"}},"description":"Returns paged hierarchies for the organisation along with the total count. Filter by name, entity code, and status; sort by any supported field."},"post":{"tags":["Hierarchies"],"summary":"Create hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Creates one or more hierarchies. When `CreateWithTopLevelRoots` is true, the server discovers top-level roots from the supplied edge type/direction and uses them as project roots; when `CreateMultiProjects` is true, one hierarchy is created per root (subject to the organisation's multi-project limit — exceeding the limit returns 500 with an explanatory message)."},"put":{"tags":["Hierarchies"],"summary":"Update hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Updates an existing hierarchy. Returns 400 with validation details when the model is invalid or the id is empty, and 404 when the hierarchy cannot be found."}},"/api/hierarchies/{id}":{"get":{"tags":["Hierarchies"],"summary":"Get hierarchy","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK"}},"description":"Returns a hierarchy by id. Returns 404 if it cannot be found."},"delete":{"tags":["Hierarchies"],"summary":"Delete hierarchy","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK"}},"description":"Deletes a hierarchy. Returns 404 if it cannot be found."}},"/api/v1/hierarchies/{id}":{"get":{"tags":["Hierarchies"],"summary":"Get hierarchy","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK"}},"description":"Returns a hierarchy by id. Returns 404 if it cannot be found."},"delete":{"tags":["Hierarchies"],"summary":"Delete hierarchy","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK"}},"description":"Deletes a hierarchy. Returns 404 if it cannot be found."}},"/api/hierarchies/edgeTypes":{"get":{"tags":["Hierarchies"],"summary":"List edge types for hierarchy building","parameters":[{"name":"entityType","in":"query","schema":{"type":"string"},"description":"Entity type to inspect."}],"responses":{"200":{"description":"OK"}},"description":"Returns the edge types that can be used to extend a hierarchy from the supplied entity type. Used by the hierarchy builder UI to populate the edge picker."}},"/api/v1/hierarchies/edgeTypes":{"get":{"tags":["Hierarchies"],"summary":"List edge types for hierarchy building","parameters":[{"name":"entityType","in":"query","schema":{"type":"string"},"description":"Entity type to inspect."}],"responses":{"200":{"description":"OK"}},"description":"Returns the edge types that can be used to extend a hierarchy from the supplied entity type. Used by the hierarchy builder UI to populate the edge picker."}},"/api/hierarchies/refresh":{"post":{"tags":["Hierarchies"],"summary":"Refresh hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Refreshes a hierarchy by replaying patches against the latest entity graph, producing a new version and (optionally) limited to a set of target entity codes. Returns 400 when the model is invalid or the hierarchy id is empty, and 404 when the hierarchy cannot be found."}},"/api/v1/hierarchies/refresh":{"post":{"tags":["Hierarchies"],"summary":"Refresh hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Refreshes a hierarchy by replaying patches against the latest entity graph, producing a new version and (optionally) limited to a set of target entity codes. Returns 400 when the model is invalid or the hierarchy id is empty, and 404 when the hierarchy cannot be found."}},"/api/hierarchies/previewEntities":{"post":{"tags":["Hierarchies"],"summary":"Preview entities to append","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Previews the entities that would be appended to a hierarchy if the supplied edge type + direction were applied. Returns the previewed nodes and an estimate of the total number of nodes the full append would produce. Returns 400 with validation details when the model is invalid."}},"/api/v1/hierarchies/previewEntities":{"post":{"tags":["Hierarchies"],"summary":"Preview entities to append","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Previews the entities that would be appended to a hierarchy if the supplied edge type + direction were applied. Returns the previewed nodes and an estimate of the total number of nodes the full append would produce. Returns 400 with validation details when the model is invalid."}},"/api/hierarchies/appendEntities":{"post":{"tags":["Hierarchies"],"summary":"Append entities from an edge type","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Extends an existing hierarchy with entities reachable through the supplied edge type and direction. Returns the resulting trees so the UI can render the new branches."}},"/api/v1/hierarchies/appendEntities":{"post":{"tags":["Hierarchies"],"summary":"Append entities from an edge type","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Extends an existing hierarchy with entities reachable through the supplied edge type and direction. Returns the resulting trees so the UI can render the new branches."}},"/api/hierarchies/entities":{"post":{"tags":["Hierarchies"],"summary":"Get entities reachable through an edge type","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Returns entities reachable from a hierarchy through a specific edge type and direction, optionally narrowed by keyword. Used by the hierarchy builder to populate node pickers. Returns 404 when an upstream resource cannot be found."}},"/api/v1/hierarchies/entities":{"post":{"tags":["Hierarchies"],"summary":"Get entities reachable through an edge type","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Returns entities reachable from a hierarchy through a specific edge type and direction, optionally narrowed by keyword. Used by the hierarchy builder to populate node pickers. Returns 404 when an upstream resource cannot be found."}},"/api/hierarchies/clone":{"post":{"tags":["Hierarchies"],"summary":"Clone hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Clones a hierarchy and returns the new hierarchy id. Returns 400 when the source id is empty and 404 when the source hierarchy cannot be found."}},"/api/v1/hierarchies/clone":{"post":{"tags":["Hierarchies"],"summary":"Clone hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Clones a hierarchy and returns the new hierarchy id. Returns 400 when the source id is empty and 404 when the source hierarchy cannot be found."}},"/api/hierarchies/publish":{"post":{"tags":["Hierarchies"],"summary":"Publish hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Publishes a hierarchy so it is available to downstream consumers, returning the published hierarchy model. Returns 400 when the id is empty and 404 when the hierarchy cannot be found."}},"/api/v1/hierarchies/publish":{"post":{"tags":["Hierarchies"],"summary":"Publish hierarchy","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel"}}}},"responses":{"200":{"description":"OK"}},"description":"Publishes a hierarchy so it is available to downstream consumers, returning the published hierarchy model. Returns 400 when the id is empty and 404 when the hierarchy cannot be found."}},"/api/hierarchies/{id}/publishStatus":{"get":{"tags":["Hierarchies"],"summary":"Get hierarchy publish status","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK"}},"description":"Returns the publish progress and status for the hierarchy. Returns 404 if it cannot be found."}},"/api/v1/hierarchies/{id}/publishStatus":{"get":{"tags":["Hierarchies"],"summary":"Get hierarchy publish status","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK"}},"description":"Returns the publish progress and status for the hierarchy. Returns 404 if it cannot be found."}},"/api/hierarchies/{id}/export":{"get":{"tags":["Hierarchies"],"summary":"Export hierarchy as CSV","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK","content":{"text/csv":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"Not Found"},"500":{"description":"Internal Server Error"}},"description":"Exports the hierarchy as CSV. Response is `text/csv` with `Content-Disposition: attachment; filename=hierarchy-{id}.csv`. Returns 404 if the hierarchy cannot be found."}},"/api/v1/hierarchies/{id}/export":{"get":{"tags":["Hierarchies"],"summary":"Export hierarchy as CSV","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"Hierarchy identifier."}],"responses":{"200":{"description":"OK","content":{"text/csv":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"Not Found"},"500":{"description":"Internal Server Error"}},"description":"Exports the hierarchy as CSV. Response is `text/csv` with `Content-Disposition: attachment; filename=hierarchy-{id}.csv`. Returns 404 if the hierarchy cannot be found."}}},"components":{"schemas":{"CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelResponseModel":{"type":"object","properties":{"edges":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelEdge"},"nullable":true,"readOnly":true},"nodes":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelNode"},"nullable":true,"readOnly":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyModel":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"organizationId":{"type":"string","format":"uuid"},"name":{"type":"string","nullable":true},"entityType":{"type":"string","nullable":true},"status":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyProjectState"},"numberOfNodes":{"type":"integer","format":"int32","nullable":true},"createdAt":{"type":"string","format":"date-time"},"createdBy":{"type":"string","format":"uuid","nullable":true},"modifiedAt":{"type":"string","format":"date-time","nullable":true},"modifiedBy":{"type":"string","format":"uuid","nullable":true},"isDeleted":{"type":"boolean"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"},"previousRevisions":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchySummaryModel"},"nullable":true},"relationships":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyNode"},"nullable":true},"entityEdgeType":{"type":"string","nullable":true},"entityEdgeDirection":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.EdgeDirection"},"createWithTopLevelRoots":{"type":"boolean"},"createMultiProjects":{"type":"boolean"},"rootNodeOriginEntityCodes":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.SelectedRootHierarchyNodeModel"},"nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.UpdateHierarchyModel":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"organizationId":{"type":"string","format":"uuid"},"name":{"type":"string","nullable":true},"entityType":{"type":"string","nullable":true},"status":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyProjectState"},"numberOfNodes":{"type":"integer","format":"int32","nullable":true},"createdAt":{"type":"string","format":"date-time"},"createdBy":{"type":"string","format":"uuid","nullable":true},"modifiedAt":{"type":"string","format":"date-time","nullable":true},"modifiedBy":{"type":"string","format":"uuid","nullable":true},"isDeleted":{"type":"boolean"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"},"previousRevisions":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchySummaryModel"},"nullable":true},"patches":{"$ref":"#/components/schemas/Microsoft.AspNetCore.JsonPatch.JsonPatchDocument`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]"}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.RefreshHierarchyModel":{"type":"object","properties":{"hierarchyId":{"type":"string","format":"uuid"},"patches":{"$ref":"#/components/schemas/Microsoft.AspNetCore.JsonPatch.JsonPatchDocument`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"},"targetEntityCodes":{"type":"array","items":{"type":"string"},"nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PreviewEntitiesModel":{"required":["edgeType","patches"],"type":"object","properties":{"hierarchyId":{"type":"string","format":"uuid"},"patches":{"$ref":"#/components/schemas/Microsoft.AspNetCore.JsonPatch.JsonPatchDocument`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"},"hierarchy":{"type":"string","nullable":true},"edgeType":{"minLength":1,"type":"string"},"edgeDirection":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.EdgeDirection"},"newTreesOption":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.NewTreesOption"},"targetEntityCodes":{"type":"array","items":{"type":"string"},"nullable":true},"keyword":{"type":"string","nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.AppendEntitiesFromEdgesModel":{"required":["edgeType","patches"],"type":"object","properties":{"hierarchyId":{"type":"string","format":"uuid"},"patches":{"$ref":"#/components/schemas/Microsoft.AspNetCore.JsonPatch.JsonPatchDocument`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"},"edgeType":{"minLength":1,"type":"string"},"edgeDirection":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.EdgeDirection"},"newTreesOption":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.NewTreesOption"},"targetEntityCodes":{"type":"array","items":{"type":"string"},"nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.GetEntitiesFromEdgeTypeModel":{"type":"object","properties":{"edgeType":{"type":"string","nullable":true},"keyword":{"type":"string","nullable":true},"take":{"type":"integer","format":"int32","nullable":true},"edgeDirection":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.EdgeDirection"}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.CloneHierarchyModel":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string","nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.PublishHierarchyModel":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelEdge":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true},"type":{"type":"string","nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Governance.GlobalDataModel.Models.GlobalDataModelNode":{"type":"object","properties":{"id":{"type":"string","nullable":true},"displayName":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"icon":{"type":"string","nullable":true},"x":{"type":"integer","format":"int32"},"y":{"type":"integer","format":"int32"}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyProjectState":{"enum":[0,1,2,3],"type":"integer","format":"int32"},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchySummaryModel":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"organizationId":{"type":"string","format":"uuid"},"name":{"type":"string","nullable":true},"entityType":{"type":"string","nullable":true},"status":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyProjectState"},"numberOfNodes":{"type":"integer","format":"int32","nullable":true},"createdAt":{"type":"string","format":"date-time"},"createdBy":{"type":"string","format":"uuid","nullable":true},"modifiedAt":{"type":"string","format":"date-time","nullable":true},"modifiedBy":{"type":"string","format":"uuid","nullable":true},"isDeleted":{"type":"boolean"},"majorVersion":{"type":"integer","format":"int32"},"minorVersion":{"type":"integer","format":"int32"},"previousRevisions":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchySummaryModel"},"nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyNode":{"type":"object","properties":{"displayName":{"type":"string","nullable":true},"entityId":{"type":"string","nullable":true},"entityType":{"type":"string","nullable":true},"originEntityCode":{"type":"string","nullable":true},"previewUrl":{"type":"string","nullable":true},"iconName":{"type":"string","nullable":true},"children":{"type":"array","items":{"$ref":"#/components/schemas/CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.HierarchyNode"},"nullable":true}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.EdgeDirection":{"enum":[0,1],"type":"integer","format":"int32"},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.SelectedRootHierarchyNodeModel":{"type":"object","properties":{"label":{"type":"string","nullable":true},"value":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.JsonPatch.JsonPatchDocument`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]":{"type":"object","properties":{"operations":{"type":"array","items":{"$ref":"#/components/schemas/Microsoft.AspNetCore.JsonPatch.Operations.Operation`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]"},"nullable":true,"readOnly":true},"contractResolver":{"$ref":"#/components/schemas/Newtonsoft.Json.Serialization.IContractResolver"}},"additionalProperties":false},"CluedIn.Server.WebApi.Controllers.Management.Hierarchies.Models.NewTreesOption":{"enum":[0,1],"type":"integer","format":"int32"},"Microsoft.AspNetCore.JsonPatch.Operations.Operation`1[[System.Collections.Generic.List`1[[CluedIn.Hierarchies.Storage.Models.HierarchyNode, CluedIn.Hierarchies, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=10.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]":{"type":"object","properties":{"operationType":{"$ref":"#/components/schemas/Microsoft.AspNetCore.JsonPatch.Operations.OperationType"},"path":{"type":"string","nullable":true},"op":{"type":"string","nullable":true},"from":{"type":"string","nullable":true},"value":{"nullable":true}},"additionalProperties":false},"Newtonsoft.Json.Serialization.IContractResolver":{"type":"object","additionalProperties":false},"Microsoft.AspNetCore.JsonPatch.Operations.OperationType":{"enum":[0,1,2,3,4,5,6],"type":"integer","format":"int32"}},"securitySchemes":{"Bearer":{"type":"http","description":"Please enter a valid token","scheme":"Bearer"}}}}