Assign connected object as an asynchronous operation. Returns (Task)Exception Type: ArgumentNullExceptionTarget.Href, Target.Links or connectedObject.Key is missing Assign connected object as an asynchronous operation. Returns (Task)Exception Type: ArgumentNullExceptiontargetHref, connectionLink, relation or connectedObjectKey is missing
Associate two Base objects together and specify how they are to interact (their relationship).
| Name | Description |
|---|---|
| target | The target. |
| connectedObject | The connected object. |
| relation | The relation. |
| isOneToOne | if set to true establishes a one-to-one relationship. |
| metaData | Provides space for additional data about the intersection of the two related resources. |
| addAsTag | if set to true adds the connection as a tag. |
| targetHref | The target object’s href. |
| connectionLink | The connection link ( "connections" or "connections2" )If "connections" , the meta must be a byte[] BSON encoded BsonDocumentIf "connections2" , the meta must be a JObject |
| connectedObjectKey | The connected object’s key. |
| relation | The relation. |
| isOneToOne | if set to true establishes a one-to-one relationship. |
| meta | Provides space for additional data about the intersection of the two related resourcesIf connectionsLink == "connections" , pass in a byte[] BSON encoded BsonDocumentIf connectionsLink == "connections2" , pass in a JObject |
| addAsTag | if set to true adds the connection as a tag. |
Example in C#
// Returns: nothing
await client.AssignConnectedObjectAsync(BaseInfo target, BaseInfo connectedObject, String relation, Boolean isOneToOne, Object metaData, Boolean addAsTag);
Example in C#
// Returns: nothing
await client.AssignConnectedObjectAsync(String targetHref, String connectionLink, String connectedObjectKey, String relation, Boolean isOneToOne, Object meta, Boolean addAsTag);
Example in CURL
curl -X PUT \
https://api.us.acresecurity.cloud/api/f/INSTANCE.KEY/people/PERSON.KEY/connections/RELATION?isOneToOne=True&relatedKey=RELATED.KEY;addAsTag=false \
-H 'Authorization: Bearer TOKEN_GOES_HERE' \
-H 'Content-Type: application/json' \
-d 'null'
Example in CURL
curl -X PUT \
https://api.us.acresecurity.cloud/api/f/INSTANCE.KEY/people/PERSON.KEY/connections/RELATION?isOneToOne=True&relatedKey=RELATED.KEY;addAsTag=false \
-H 'Authorization: Bearer TOKEN_GOES_HERE' \
-H 'Content-Type: application/json' \
-d 'null'