HomeGuidesAPI ReferenceChangelogDiscussions
GuidesiMIS ProfessionaliMIS EnterpriseClient SupportLog In
Discussions

Discussions

Ask a Question
Back to All

Creating a relationship

I queried a certain relationship with the REST API. This is production data:
{
"$type": "Asi.Soa.Membership.DataContracts.GroupMemberData, Asi.Contracts",
"MembershipDetails": {
"$type": "Asi.Soa.Membership.DataContracts.GroupMemberDetailDataCollection, Asi.Contracts",
"$values": [
{
"$type": "Asi.Soa.Membership.DataContracts.GroupMemberDetailData, Asi.Contracts",
"GroupMemberDetailId": "RELATIONSHIP-10548:2519:3168",
"Stage": {
"$type": "Asi.Soa.Membership.DataContracts.GroupStageData, Asi.Contracts"
},
"ExpirationDate": "2016-07-13T00:00:00",
"Role": {
"$type": "Asi.Soa.Membership.DataContracts.GroupRoleData, Asi.Contracts",
"DefaultReciprocalRoleId": "NPEEXH",
"DefaultReciprocalDescription": "NPE Exhibitor Contact",
"DefaultReciprocalName": "NPEEXH",
"RoleId": "RELATIONSHIP:NPEEXH",
"Description": "NPE Exhibitor Contact",
"Name": "NPEEXH"
},
"ReciprocalRole": {
"$type": "Asi.Soa.Membership.DataContracts.GroupRoleData, Asi.Contracts",
"DefaultReciprocalDescription": "NPE Exhibitor Contact",
"DefaultReciprocalName": "NPEEXH",
"RoleId": "RELATIONSHIP:NPEEXH",
"Description": "NPE Exhibitor Contact",
"Name": "NPEEXH"
},
"Title": ""
}
]
},
"GroupMemberId": "RELATIONSHIP-10548:2519",
"Group": {
"$type": "Asi.Soa.Membership.DataContracts.GroupSummaryData, Asi.Contracts",
"GroupId": "RELATIONSHIP-10548",
"Name": "C. Todd Reed Relationship",
"Description": "Relationships",
"ParentIdentity": {
"$type": "Asi.Soa.Core.DataContracts.IdentityData, Asi.Contracts",
"EntityTypeName": "Party",
"IdentityElements": {
"$type": "System.Collections.ObjectModel.Collection`1[[System.String, mscorlib]], mscorlib",
"$values": [
"10548"
]
}
},
"GroupClass": {
"$type": "Asi.Soa.Membership.DataContracts.GroupClassSummaryData, Asi.Contracts",
"GroupClassId": "RELATIONSHIP",
"Name": "Relationship",
"Description": "",
"IsRelationshipGroup": true
},
"IsRelationshipGroup": true
},
"Party": {
"$type": "Asi.Soa.Membership.DataContracts.PartySummaryData, Asi.Contracts",
"CityName": "Holland",
"CountryName": "United States",
"CountrySubEntityName": "MI",
"Email": "",
"Phone": "(616) 399-2220",
"PartyId": "2519",
"Id": "2519",
"UniformId": "7f6e7fb6-5585-459f-a812-2aa92fd7a3b4",
"Status": {
"$type": "Asi.Soa.Membership.DataContracts.PartyStatusData, Asi.Contracts",
"PartyStatusId": "A",
"Name": "Active",
"Description": "Active"
},
"Name": "National Bulk Equipment, Inc.",
"Sort": "NATIONAL BULK EQUIPMENT, INC.",
"IsMarkedForDelete": false
},
"IsActive": false
}

Using that information, I'm trying to put together the JSON to create a new relationship like that one. Here's my JSON:

{
"$type": "Asi.Soa.Membership.DataContracts.GroupMemberData, Asi.Contracts",
"MembershipDetails": {
"$type": "Asi.Soa.Membership.DataContracts.GroupMemberDetailDataCollection, Asi.Contracts",
"$values": [
{
"$type": "Asi.Soa.Membership.DataContracts.GroupMemberDetailData, Asi.Contracts",
"GroupMemberDetailId": "RELATIONSHIP-688683:50",
"Stage": {
"$type": "Asi.Soa.Membership.DataContracts.GroupStageData, Asi.Contracts"
},
"Role": {
"$type": "Asi.Soa.Membership.DataContracts.GroupRoleData, Asi.Contracts",
"DefaultReciprocalRoleId": "NPEEXH",
"DefaultReciprocalDescription": "NPE Exhibitor Contact",
"DefaultReciprocalName": "NPEEXH",
"RoleId": "RELATIONSHIP:NPEEXH",
"Description": "NPE Exhibitor Contact",
"Name": "NPEEXH"
}
"ReciprocalRole": {
"$type": "Asi.Soa.Membership.DataContracts.GroupRoleData, Asi.Contracts",
"DefaultReciprocalRoleId": "NPEEXH",
"DefaultReciprocalDescription": "NPE Exhibitor Contact",
"RoleId": "RELATIONSHIP:NPEEXH",
"Description": "NPE Exhibitor Contact",
"Name": "NPEEXH"
},
"Title": ""
}
]
},
"GroupMemberId": "RELATIONSHIP-688683:50",
"Group": {
"$type": "Asi.Soa.Membership.DataContracts.GroupSummaryData, Asi.Contracts",
"GroupId": "RELATIONSHIP-688683",
"ParentIdentity": {
"$type": "Asi.Soa.Core.DataContracts.IdentityData, Asi.Contracts",
"EntityTypeName": "Party",
"IdentityElements": {
"$type": "System.Collections.ObjectModel.Collection`1[[System.String, mscorlib]], mscorlib",
"$values": [
"688683"
]
}
},
"GroupClass": {
"$type": "Asi.Soa.Membership.DataContracts.GroupClassSummaryData, Asi.Contracts",
"GroupClassId": "RELATIONSHIP",
"Name": "Relationship",
"Description": ""
"IsRelationshipGroup": true
},
"IsRelationshipGroup": true
},
"Party": {
"$type": "Asi.Soa.Membership.DataContracts.PartySummaryData, Asi.Contracts",
"PartyId": "50",
"Id": "50",
"UniformId": "F77BE941-2EE4-4125-B574-7FE4E6369E6B",
"Status": {
"$type": "Asi.Soa.Membership.DataContracts.PartyStatusData, Asi.Contracts",
"PartyStatusId": "A",
"Name": "Active",
"Description": "Active"
},
"IsMarkedForDelete": false
}
"IsActive": true
}

It looks right to me, and those are real IDs and GUIDs. Can anyone tell what I'm doing wrong?

Contact us
Copyright © Advanced Solutions International, All rights reserved.