Enumerating customers

To get the list of customers for your own company or your customers, use the EnumeratePartners method.

Required parameters

ParameterDescriptionSupported values
parentPartnerIdThe ID of the parent customer<int> Integer

Optional parameters

ParameterDescriptionSupported values
fetchRecursivelyThe range of customers to retrievebool Boolean
  • true (returns the full list of customers)
  • false (returns only 1 level of customers)
fieldsLets you specify the type of information you need

PartnerFields

Numbers of fields separated by a comma in square brackets:
  • 0 - Name
  • 1 - Level
  • 3 - ChildServiceTypes
  • 4 - ServiceType
  • 5 - State
  • 8 - LocationId
  • 9 - Flags
  • 10 - Company info
  • 18 - ExternalCode, MailFrom
  • 20 - CreationTime

Sample request

{
    "id": "jsonrpc",
    "visa": "{{visa}}",
    "method": "EnumeratePartners",
    "jsonrpc": "2.0",
    "params": {
	    "parentPartnerId": 12345,
	    "fields": [0, 1, 3, 4, 5, 8],
	    "fetchRecursively": true
    }
}

Sample response

{
    "id": "jsonrpc",
    "jsonrpc": "2.0",
    "result": {
	"result":	[
	    {
		"ChildServiceTypes":
		[
		    "AllInclusive",
		    "SoftwareOnly"
		],
		    "Company": {"PostAddress": null},
		    "ExternalPartnerProperties": null,
		    "Id": 45678,
		    "Level": "SubDistributor",
		    "LocationId": 1,
		    "Name": "WindowsDevices",
		    "ParentId": 12345,
		    "ServiceType": "AllInclusive",
		    "State": "InTrial"
	    },
	    {
		"ChildServiceTypes":
		[
		    "AllInclusive",
		    "SoftwareOnly"
		],
		    "Company": {"PostAddress": null},
		    "ExternalPartnerProperties": null,
		    "Id": 34567,
		    "Level": "SubDistributor",
		    "LocationId": 1,
		    "Name": "LinuxDevices",
		    "ParentId": 12345,
		    "ServiceType": "AllInclusive",
		    "State": "Registered"
	    },
	    {
		    "ChildServiceTypes": null,
		    "Company": {"PostAddress": null},
		    "ExternalPartnerProperties": null,
		    "Id": 23456,
		    "Level": "EndCustomer",
		    "LocationId": 1,
		    "Name": "Zeus & Sons",
		    "ParentId": 12345,
		    "ServiceType": "AllInclusive",
		    "State": "Registered"
	    }
	    ]
    },
    "visa": "{{visa}}"
}

Did this page help you?