Relations
Parents
You can query for named parent relationships by using a specific ID.
For instance, to query for all assets linked to a certain brand ID:
GET http://<hostname>/api/entities/query?query=Definition.Name=='M.Asset' AND Parent('BrandToAsset').id==331
This property only supports the == operator, but can be negated.
Children
You can query for named child relationships by using a specific ID.
For instance, to query for all assets that have another specific asset as child:
GET http://<hostname>/api/entities/query?query=Definition.Name=='M.Asset' AND Child('RelatedAssetsToAsset').id==407
This property only supports the == operator, but can be negated.
Ancestors
You can query for named ancestors (secured and unsecured) by using a specific ID.
For instance, to query for all assets that belong to M.AssetMedia:
GET http://<hostname>/api/entities/query?query=Definition.Name=='M.Asset' AND Ancestor('AssetMediaToAsset').id==317
This property only supports the == operator, but can be negated.
Exists
You can query for named relationships which have a parent entity.
For instance, to query for all assets which have a brand:
GET http://<hostname>/api/entities/query?query=Definition.Name=='M.Asset' AND Exists('BrandToAsset')
Missing
You can query for named relationships which do not have a parent entity.
For instance, to query for all assets which do not have a brand:
GET http://<hostname>/api/entities/query?query=Definition.Name=='M.Asset' AND Missing('BrandToAsset')