Trendsic Platform Service

<back to all web services

AgentRequest

Requires Authentication
Requires any of the roles:Worker, Agent, Administrator, Worker, Agent, Administrator
The following routes are available for this service:
GET/v1/Agent/{AgentId}
GET,POST,PUT,DELETE,OPTIONS/v1/Agent
GET/v1/Agent/ByUserId/{UserId}
GET,POST,PUT,DELETE,OPTIONS/v1/Agent/Hierarchy/{ParamGetHierarchy}
GET,OPTIONS/v1/Agent/Hierarchy/{ParamGetHierarchy}/{ParamDistinct}/{NewAgents}
GET,OPTIONS/v1/Agent/Hierarchy/{ParamGetHierarchy}/{ParamDistinct}
AgentRequest Parameters:
NameParameterData TypeRequiredDescription
AgentbodyList<Agent>No
ParamGetHierarchypathboolNo
ParamDistinctpathboolNo
NewAgentspathboolNo
AgentIdpathintNo
LocationbodyGuidNo
UserIdpathGuidNo
ServicesbodyList<string>No
Agent Parameters:
NameParameterData TypeRequiredDescription
AgentIdformintNo
CompanyformstringNo
AgentNameformstringNo
FirstNameformstringNo
LastNameformstringNo
MiddleInitialformstringNo
Address1formstringNo
Address2formstringNo
CityformstringNo
StateformstringNo
ZipformstringNo
CountryformstringNo
EmailformstringNo
EmailSignatureformstringNo
HomePhoneformstringNo
CellPhoneformstringNo
WorkPhoneformstringNo
InsLicensedformboolNo
AgreeToDisclosuresformboolNo
AgreeToDateformDateTime?No
PaidDateformDateTime?No
AgentNumberformstringNo
ReferringAgentformstringNo
PlacementAgentformstringNo
CreatedDateformDateTime?No
UserIdformGuidNo
IsAgentformboolNo
PackageformstringNo
StoreNameformstringNo
NotesformstringNo
Upline1formint?No
Upline2formint?No
Upline3formint?No
Upline4formint?No
MVPIDformint?No
AVPIDformint?No
RVPIDformint?No
AgentLevelformdecimal?No
IsMVPformboolNo
IsRVPformboolNo
IsAVPformboolNo
IsAdminformboolNo
IsBusinessCardAdminformboolNo
TeamNameformstringNo
LocationIdformGuidNo
CalendarIdformGuidNo
RankformstringNo
NBCformboolNo
Upline1Percentformdecimal?No
Upline2Percentformdecimal?No
Upline3Percentformdecimal?No
Upline4Percentformdecimal?No
AgentStatusformstringNo
OfficeformstringNo
DOBformDateTime?No
SSNformstringNo
FaxformstringNo
BusinessEmailformstringNo
ModifiedDateformDateTime?No
ModifiedByformstringNo
TimeZoneformstringNo
LeaderLockedformboolNo
LastSubmittedBusinessDateformDateTimeNo
GracePeriodDateformDateTimeNo
VestedformboolNo
DirectPayformDateTimeNo
DirectPayApprByformstringNo
FactFinderBillingformdecimal?No
FullNameformstringNo
ByLastNameformstringNo
IsSecurityLicensedformboolNo
IsEncompassAdminformboolNo
ApiKeyformGuidNo
LastSessionIdformstringNo
LastLoginformDateTime?No
MfaActiveformboolNo
RequireMFAformboolNo
SMSPhoneNumberformstringNo
VerifiedEmailStatusformboolNo
VerifiedCellPhoneStatusformboolNo
SchedulerUrlformstringNo
QueueDefaultsformQueueDefaultNo
RolesformList<string>No
PasswordUpdatedformboolNo
RestrictToSingleSessionformboolNo
QueueDefault Parameters:
NameParameterData TypeRequiredDescription
LocationIdformGuidNo
ServicesformList<Guid>No
AgentResponse Parameters:
NameParameterData TypeRequiredDescription
ResponseStatusformResponseStatusNo
AgentformList<Agent>No

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /v1/Agent HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<AgentRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <Agent>
    <Agent>
      <AVPID>0</AVPID>
      <Address1>String</Address1>
      <Address2>String</Address2>
      <AgentId>0</AgentId>
      <AgentLevel>0</AgentLevel>
      <AgentName>String</AgentName>
      <AgentNumber>String</AgentNumber>
      <AgentStatus>String</AgentStatus>
      <AgreeToDate>0001-01-01T00:00:00</AgreeToDate>
      <AgreeToDisclosures>false</AgreeToDisclosures>
      <ApiKey>00000000-0000-0000-0000-000000000000</ApiKey>
      <BusinessEmail>String</BusinessEmail>
      <ByLastName>String</ByLastName>
      <CalendarId>00000000-0000-0000-0000-000000000000</CalendarId>
      <CellPhone>String</CellPhone>
      <City>String</City>
      <Company>String</Company>
      <Country>String</Country>
      <CreatedDate>0001-01-01T00:00:00</CreatedDate>
      <DOB>0001-01-01T00:00:00</DOB>
      <DirectPay>0001-01-01T00:00:00</DirectPay>
      <DirectPayApprBy>String</DirectPayApprBy>
      <Email>String</Email>
      <EmailSignature>String</EmailSignature>
      <FactFinderBilling>0</FactFinderBilling>
      <Fax>String</Fax>
      <FirstName>String</FirstName>
      <FullName>String</FullName>
      <GracePeriodDate>0001-01-01T00:00:00</GracePeriodDate>
      <HomePhone>String</HomePhone>
      <InsLicensed>false</InsLicensed>
      <IsAVP>false</IsAVP>
      <IsAdmin>false</IsAdmin>
      <IsAgent>false</IsAgent>
      <IsBusinessCardAdmin>false</IsBusinessCardAdmin>
      <IsEncompassAdmin>false</IsEncompassAdmin>
      <IsMVP>false</IsMVP>
      <IsRVP>false</IsRVP>
      <IsSecurityLicensed>false</IsSecurityLicensed>
      <LastLogin>0001-01-01T00:00:00</LastLogin>
      <LastName>String</LastName>
      <LastSessionId>String</LastSessionId>
      <LastSubmittedBusinessDate>0001-01-01T00:00:00</LastSubmittedBusinessDate>
      <LeaderLocked>false</LeaderLocked>
      <LocationId>00000000-0000-0000-0000-000000000000</LocationId>
      <MVPID>0</MVPID>
      <MfaActive>false</MfaActive>
      <MiddleInitial>String</MiddleInitial>
      <ModifiedBy>String</ModifiedBy>
      <ModifiedDate>0001-01-01T00:00:00</ModifiedDate>
      <NBC>false</NBC>
      <Notes>String</Notes>
      <Office>String</Office>
      <Package>String</Package>
      <PaidDate>0001-01-01T00:00:00</PaidDate>
      <PasswordUpdated>false</PasswordUpdated>
      <PlacementAgent>String</PlacementAgent>
      <QueueDefaults>
        <LocationId>00000000-0000-0000-0000-000000000000</LocationId>
        <Services xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:guid>00000000-0000-0000-0000-000000000000</d5p1:guid>
        </Services>
      </QueueDefaults>
      <RVPID>0</RVPID>
      <Rank>String</Rank>
      <ReferringAgent>String</ReferringAgent>
      <RequireMFA>false</RequireMFA>
      <RestrictToSingleSession>false</RestrictToSingleSession>
      <Roles xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:string>String</d4p1:string>
      </Roles>
      <SMSPhoneNumber>String</SMSPhoneNumber>
      <SSN>String</SSN>
      <SchedulerUrl>String</SchedulerUrl>
      <State>String</State>
      <StoreName>String</StoreName>
      <TeamName>String</TeamName>
      <TimeZone>String</TimeZone>
      <Upline1>0</Upline1>
      <Upline1Percent>0</Upline1Percent>
      <Upline2>0</Upline2>
      <Upline2Percent>0</Upline2Percent>
      <Upline3>0</Upline3>
      <Upline3Percent>0</Upline3Percent>
      <Upline4>0</Upline4>
      <Upline4Percent>0</Upline4Percent>
      <UserId>00000000-0000-0000-0000-000000000000</UserId>
      <VerifiedCellPhoneStatus>false</VerifiedCellPhoneStatus>
      <VerifiedEmailStatus>false</VerifiedEmailStatus>
      <Vested>false</Vested>
      <WorkPhone>String</WorkPhone>
      <Zip>String</Zip>
    </Agent>
  </Agent>
  <AgentId>0</AgentId>
  <Location>00000000-0000-0000-0000-000000000000</Location>
  <NewAgents>false</NewAgents>
  <ParamDistinct>false</ParamDistinct>
  <ParamGetHierarchy>false</ParamGetHierarchy>
  <Services xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>String</d2p1:string>
  </Services>
  <UserId>00000000-0000-0000-0000-000000000000</UserId>
</AgentRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<AgentResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <Agent>
    <Agent>
      <AVPID>0</AVPID>
      <Address1>String</Address1>
      <Address2>String</Address2>
      <AgentId>0</AgentId>
      <AgentLevel>0</AgentLevel>
      <AgentName>String</AgentName>
      <AgentNumber>String</AgentNumber>
      <AgentStatus>String</AgentStatus>
      <AgreeToDate>0001-01-01T00:00:00</AgreeToDate>
      <AgreeToDisclosures>false</AgreeToDisclosures>
      <ApiKey>00000000-0000-0000-0000-000000000000</ApiKey>
      <BusinessEmail>String</BusinessEmail>
      <ByLastName>String</ByLastName>
      <CalendarId>00000000-0000-0000-0000-000000000000</CalendarId>
      <CellPhone>String</CellPhone>
      <City>String</City>
      <Company>String</Company>
      <Country>String</Country>
      <CreatedDate>0001-01-01T00:00:00</CreatedDate>
      <DOB>0001-01-01T00:00:00</DOB>
      <DirectPay>0001-01-01T00:00:00</DirectPay>
      <DirectPayApprBy>String</DirectPayApprBy>
      <Email>String</Email>
      <EmailSignature>String</EmailSignature>
      <FactFinderBilling>0</FactFinderBilling>
      <Fax>String</Fax>
      <FirstName>String</FirstName>
      <FullName>String</FullName>
      <GracePeriodDate>0001-01-01T00:00:00</GracePeriodDate>
      <HomePhone>String</HomePhone>
      <InsLicensed>false</InsLicensed>
      <IsAVP>false</IsAVP>
      <IsAdmin>false</IsAdmin>
      <IsAgent>false</IsAgent>
      <IsBusinessCardAdmin>false</IsBusinessCardAdmin>
      <IsEncompassAdmin>false</IsEncompassAdmin>
      <IsMVP>false</IsMVP>
      <IsRVP>false</IsRVP>
      <IsSecurityLicensed>false</IsSecurityLicensed>
      <LastLogin>0001-01-01T00:00:00</LastLogin>
      <LastName>String</LastName>
      <LastSessionId>String</LastSessionId>
      <LastSubmittedBusinessDate>0001-01-01T00:00:00</LastSubmittedBusinessDate>
      <LeaderLocked>false</LeaderLocked>
      <LocationId>00000000-0000-0000-0000-000000000000</LocationId>
      <MVPID>0</MVPID>
      <MfaActive>false</MfaActive>
      <MiddleInitial>String</MiddleInitial>
      <ModifiedBy>String</ModifiedBy>
      <ModifiedDate>0001-01-01T00:00:00</ModifiedDate>
      <NBC>false</NBC>
      <Notes>String</Notes>
      <Office>String</Office>
      <Package>String</Package>
      <PaidDate>0001-01-01T00:00:00</PaidDate>
      <PasswordUpdated>false</PasswordUpdated>
      <PlacementAgent>String</PlacementAgent>
      <QueueDefaults>
        <LocationId>00000000-0000-0000-0000-000000000000</LocationId>
        <Services xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:guid>00000000-0000-0000-0000-000000000000</d5p1:guid>
        </Services>
      </QueueDefaults>
      <RVPID>0</RVPID>
      <Rank>String</Rank>
      <ReferringAgent>String</ReferringAgent>
      <RequireMFA>false</RequireMFA>
      <RestrictToSingleSession>false</RestrictToSingleSession>
      <Roles xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:string>String</d4p1:string>
      </Roles>
      <SMSPhoneNumber>String</SMSPhoneNumber>
      <SSN>String</SSN>
      <SchedulerUrl>String</SchedulerUrl>
      <State>String</State>
      <StoreName>String</StoreName>
      <TeamName>String</TeamName>
      <TimeZone>String</TimeZone>
      <Upline1>0</Upline1>
      <Upline1Percent>0</Upline1Percent>
      <Upline2>0</Upline2>
      <Upline2Percent>0</Upline2Percent>
      <Upline3>0</Upline3>
      <Upline3Percent>0</Upline3Percent>
      <Upline4>0</Upline4>
      <Upline4Percent>0</Upline4Percent>
      <UserId>00000000-0000-0000-0000-000000000000</UserId>
      <VerifiedCellPhoneStatus>false</VerifiedCellPhoneStatus>
      <VerifiedEmailStatus>false</VerifiedEmailStatus>
      <Vested>false</Vested>
      <WorkPhone>String</WorkPhone>
      <Zip>String</Zip>
    </Agent>
  </Agent>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
</AgentResponse>