HomeGuidesAPI ReferenceChangelogDiscussions
GuidesiMIS ProfessionaliMIS EnterpriseClient SupportLog In
Discussions

Discussions

Ask a Question
Back to All

How to pass filters which are nested in Endpoint?

"$values": [
            {
                "$type": "Asi.Soa.Membership.DataContracts.PersonData, Asi.Contracts",
                "PersonName": {
                    "$type": "Asi.Soa.Membership.DataContracts.PersonNameData, Asi.Contracts",
                    "LastName": "MANAGER",
                    "FullName": "MANAGER"
                },
                "AdditionalAttributes": {
                    "$type": "Asi.Soa.Core.DataContracts.GenericPropertyDataCollection, Asi.Contracts",
                    "$values": [
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "CustomerTypeDescription",
                            "Value": "Staff"
                        },
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "IsMemberRecord",
                            "Value": {
                                "$type": "System.Boolean",
                                "$value": false
                            }
                        },
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "CustomerTypeCode",
                            "Value": "STAFF"
                        },
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "IsMember",
                            "Value": {
                                "$type": "System.Boolean",
                                "$value": false
                            }
                        },
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "IsInactiveMember",
                            "Value": {
                                "$type": "System.Boolean",
                                "$value": false
                            }
                        },
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "AllowAdvanceRenewal",
                            "Value": {
                                "$type": "System.Boolean",
                                "$value": false
                            }
                        },
                        {
                            "$type": "Asi.Soa.Core.DataContracts.GenericPropertyData, Asi.Contracts",
                            "Name": "JoinDate",
                            "Value": "0001-01-01T00:00:00"
                        }
                    ]
                },
                "Addresses": {
                    "$type": "Asi.Soa.Membership.DataContracts.FullAddressDataCollection, Asi.Contracts",
                    "$values": [
                        {
                            "$type": "Asi.Soa.Membership.DataContracts.FullAddressData, Asi.Contracts",
                            "AdditionalLines": {
                                "$type": "Asi.Soa.Membership.DataContracts.AddressLineDataCollection, Asi.Contracts",
                                "$values": []
                            },
                            "Address": {
                                "$type": "Asi.Soa.Membership.DataContracts.AddressData, Asi.Contracts",
                                "AddressId": "649416",
                                "VerificationStatus": 0
                            },
                            "AddresseeText": "MANAGER\r\n",
                            "AddressPurpose": "Home Address",
                            "CommunicationPreferences": {
                                "$type": "Asi.Soa.Membership.DataContracts.CommunicationPreferenceDataCollection, Asi.Contracts",
                                "$values": [
                                    {
                                        "$type": "Asi.Soa.Membership.DataContracts.CommunicationPreferenceData, Asi.Contracts",
                                        "Reason": "default"
                                    },
                                    {
                                        "$type": "Asi.Soa.Membership.DataContracts.CommunicationPreferenceData, Asi.Contracts",
                                        "Reason": "mail"
                                    },
                                    {
                                        "$type": "Asi.Soa.Membership.DataContracts.CommunicationPreferenceData, Asi.Contracts",
                                        "Reason": "bill"
                                    },
                                    {
                                        "$type": "Asi.Soa.Membership.DataContracts.CommunicationPreferenceData, Asi.Contracts",
                                        "Reason": "ship"
                                    }
                                ]
                            },
                            "FullAddressId": "649416",
                            "Salutation": {
                                "$type": "Asi.Soa.Membership.DataContracts.PartySalutationData, Asi.Contracts",
                                "SalutationMethod": {
                                    "$type": "Asi.Soa.Membership.DataContracts.PartySalutationMethodSummaryData, Asi.Contracts",
                                    "PartySalutationMethodId": "main"
                                },
                                "Text": "MANAGER"
                            }
                        }
                    ]
                },
                "AlternateIds": {
                    "$type": "Asi.Soa.Core.DataContracts.AlternateIdDataCollection, Asi.Contracts",
                    "$values": [
                        {
                            "$type": "Asi.Soa.Core.DataContracts.AlternateIdData, Asi.Contracts",
                            "Id": "2",
                            "IdType": "Id"
                        }
                    ]
                },
                "Emails": {
                    "$type": "Asi.Soa.Membership.DataContracts.EmailDataCollection, Asi.Contracts",
                    "$values": [
                        {
                            "$type": "Asi.Soa.Membership.DataContracts.EmailData, Asi.Contracts",
                            "Address": "[email protected]",
                            "EmailType": "_Primary",
                            "IsPrimary": true
                        }
                    ]
                },
                "FinancialInformation": {
                    "$type": "Asi.Soa.Membership.DataContracts.FinancialInformationData, Asi.Contracts"
                },

This is not a complete JSON

Question:
Search for Parties by IDs:
https://{{URL}}/api/party?PartyID=2

Search for Parties by lastname:
https://{{URL}}/api/party?lastname=eq:smith

That is all fine because those are direct properties under Name.
The real problem is if I have to search by a property which is nested like IsMemberRecord
How do I do it?
Many properties like Status, properties under AdditionalAttributes are nested

This URL does not work:
https://{{URL}}/api/party?IsMemberRecord=eq:false

It gives back this validation error as response

{"$type":"Asi.Soa.Core.DataContracts.ValidateResultsData, Asi.Contracts","IsValid":false,"ValidationResults":{"$type":"Asi.Soa.Core.DataContracts.ValidationResultsData, Asi.Contracts","Errors":{"$type":"Asi.Soa.Core.DataContracts.ValidationResultDataCollection, Asi.Contracts","$values":[{"$type":"Asi.Soa.Core.DataContracts.ValidationResultData, Asi.Contracts","Message":"In the query, IsMemberRecord is not a known property name."}]},"Warnings":{"$type":"Asi.Soa.Core.DataContracts.ValidationResultDataCollection, Asi.Contracts","$values":[]}}}

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