Rep

Rep(
	int RepID,
	string Rep,
	int AgencyID,
	string Agency,
	int SupplierID,
	string Supplier,
	string AssignmentCode
)

Get information for one Rep.

Request

Request Data:
You can identify the Rep in multiple ways:

  • (int, string) Rep (optional) – identify the rep by ID (int). Or by the name (string), must be provided if using the Agency parameter.
  • (int, string) Agency (optional) – identify the rep by agency (id or name) + Rep name
  • (int, string) Supplier (optional) – identify the rep by supplier (id or name) + assignment code
  • (string) AssignmentCode (optional): used along with the Supplier parameter
{
    "RepID": <int>,
    "Rep": <string>,
    "AgencyID": <int>,
    "Agency": <string>,
    "SupplierID ": <int>,
    "Supplier": <string>,
    "AssignmentCode": <string>
}

Response

{
    "Result": {
        "Added": <Date>,
        "Agency": <string>,
        "AgencyID": <int>,
        "AgencyArchived": <bool>, // Since RPM29
        "AssignmentCodes": [
            {
                "AssignmentCode": <string>, // ID
                "Supplier": <string>,
                "SupplierID": <int>
            },
            <... more AssignmentCodes>
        ],
        "CommissionsHidden": <bool>,
        "Contact": {
            "ContactID": <int>,
            "Email": <string>,
            "FirstName": <string>,
            "LastName": <string>,
            "PhoneNumbers": [
                {
                    "Number": <string>,
                    "PhoneNumberID": <int>,
                    "Type": <enum: Business=1, Home=2, Fax=3, Other=6>

                },
                <... more PhoneNumbers (1 for each type)>
            ],
            "Salutation": <string>,
            "Title": <string>
        },
        "Fields": [
        	{
                "Field": <string>, // Field Name
                "Value": <string>
            },
            ... <more custom fields>
        ],
        "Logon": <bool>, // Removed in RPM27
        "Enabled": <bool>, // Added in RPM27, replaced Logon
        "Modified": <date>,
        "NotesForStaff": [],
        "Relationship": <string>,
        "Rep": <string>,
        "RepID": <int>,
        "MgrID": <int>, // Since RPM29 (if the rep is also a manager)
        "Type": <string>,
        "Username": <string>,
        "UserID": <int>, // Since RPM29
    }
}

Errors

  • “Supplier not found”
  • “Agency not found”
  • “Rep not found”
%d bloggers like this: