ca-orbus-sapi
Relationships
GET - /odata/relationships
Summary:
Gets Relationships and their details.
Description:
Default response includes the list of 50 Relationships, which were most recently created in OrbusInfinity, and their top-level properties.
Use the below OData parameters to filter, order, expand additional properties, and select only specified properties in the output.
Query Parameters
Name | Type | Description |
---|---|---|
$select | string | A subset of properties to include for each Relationship in the response. If left blank, default properties are returned. |
$expand | string | The additional properties (along with the default ones) to include for each Relationship in the response. You can additionally request the following properties: LeadObject, LeadRelationship, MemberObject, RelationshipType, Model, AttributeValues, AttributeValuesFlat, Detail. |
$filter | string | The expression you filter the Relationships in the result by. You can filter Relationships by a value for the following properties: RelationshipId, RelationshipTypeId, ModelId, RelationshipType, Model, LeadObjectId, LeadRelationshipId, MemberObjectId, Detail. The minimum and default number of expressions is 0; the maximum—100. |
$orderby | string | The order in which Relationships are sorted in the response, by a selected property. For example, enter DateCreated desc to request Relationships in descending order by property DateCreated. The minimum and default number of expressions is 0; the maximum—5. |
$top | integer | The count of the Relationships, which were most recently created in OrbusInfinity, to include in the response. The minimum value is 0; the maximum—50. For example, enter 20 to return 20 Relationships that were most recently created in OrbusInfinity. |
$skip | integer | The count of the Relationships, which were most recently created in OrbusInfinity, to exclude from the response. The minimum and default value is 0; the maximum—50. For example, enter 20 to skip 20 Relationships that were most recently created in OrbusInfinity and return the next 50. |
$count | boolean | If true, the total count of Relationships is specified in the response. By default, the parameter is set to false, which means the total count is not returned. |
POST - /odata/relationships
Summary:
Creates a new Relationship.
Description:
You must specify Relationship Type ID, Model ID, Relationship Type Pair ID, Lead Object ID, Member Object ID, and Identifying Attribute(s) for the new Relationship. Use AttributeValuesFlat property to specify Attribute values in the key-value format.
Body
Description:
Property values for a new Relationship. Specify RelationshipTypeId, ModelId, RelationshipTypePairId, LeadModelItemId, MemberModelItemId to create a Relationship.
Optionally specify additional properties, following the structure in the example.
Default value : OrderedMap { "RelationshipTypeId": "9fac2395-ee1c-4eff-9948-ca3e43eb4ab2", "ModelId": "e0b919e5-58cc-4112-b2cf-661959d8f5e0", "RelationshipTypePairId": "28151c70-414f-463a-847d-f27bf3f2537d", "LeadModelItemId": "01f357ae-5100-4bf3-b7a2-2692867cb3c2", "MemberModelItemId": "537f028a-bb37-4e2c-950e-a2b58fa97dbd", "AttributeValuesFlat": OrderedMap { "Name": "Relates to Data Base", "Description": "Relates to Data Base", "LinksKey": List [ OrderedMap { "Url": "www.example.com", "DisplayValue": "Example Link" } ], "ChoicesKey": List [ OrderedMap { "AttributeConfigurationChoiceId": "bb8467a9-8cd2-4630-9f7f-716c5c4e4c58", "Children": List [] } ] } }
Example
{
"RelationshipTypeId": "9fac2395-ee1c-4eff-9948-ca3e43eb4ab2",
"ModelId": "e0b919e5-58cc-4112-b2cf-661959d8f5e0",
"RelationshipTypePairId": "28151c70-414f-463a-847d-f27bf3f2537d",
"LeadModelItemId": "01f357ae-5100-4bf3-b7a2-2692867cb3c2",
"MemberModelItemId": "537f028a-bb37-4e2c-950e-a2b58fa97dbd",
"AttributeValuesFlat": {
"Name": "Relates to Data Base",
"Description": "Relates to Data Base",
"LinksKey": [
{
"Url": "www.example.com",
"DisplayValue": "Example Link"
}
],
"ChoicesKey": [
{
"AttributeConfigurationChoiceId": "bb8467a9-8cd2-4630-9f7f-716c5c4e4c58",
"Children": []
}
]
}
}
PATCH - /odata/relationships/{key}
Updates Attribute values of an existing Relationship.
Description:
Use AttributeValuesFlat property to specify Attribute values in the key-value format. Only specified Attribute values will be updated.
Parameters
Name | Type | Description |
---|---|---|
key | string | ID of a Relationship in the GUID format, for example 00000000-0000-0000-0000-000000000000. |
body | object | Attribute value(s) to update for the specified Relationship. For each Attribute, specify AttributeName, AttributeCategory, and TextValue. Default value : OrderedMap { "AttributeValuesFlat": OrderedMap { "Name": "Relates to Data Base", "Description": "Relates to Data Base", "LinksKey": List [ OrderedMap { "Url": "www.example.com", "DisplayValue": "Example Link" } ], "ChoicesKey": List [ OrderedMap { "AttributeConfigurationChoiceId": "b596b2b8-51b0-4512-9ca8-56c8877143a0", "Children": List [] } ] } } |
Example
{
"AttributeValuesFlat": {
"Name": "Relates to Data Base",
"Description": "Relates to Data Base",
"LinksKey": [
{
"Url": "www.example.com",
"DisplayValue": "Example Link"
}
],
"ChoicesKey": [
{
"AttributeConfigurationChoiceId": "b596b2b8-51b0-4512-9ca8-56c8877143a0",
"Children": []
}
]
}
}