NAV

<back to all web services

LeadUpgrade

The following routes are available for this service:
POST/upgrade-lead
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports NAV.ServiceModel

Namespace Global

    Namespace NAV.ServiceModel

        Public Partial Class LeadUpgrade
            Implements IPost
            Public Overridable Property BeeNumber As Decimal
            Public Overridable Property EmailAddress As String
            Public Overridable Property MentorBeeNumber As Nullable(Of Decimal)
            Public Overridable Property Language As String
            Public Overridable Property BirthDate As Nullable(Of Date)
            Public Overridable Property PrimaryPhone As NAVPhoneUpdate
            Public Overridable Property AdditionalPhone As NAVPhoneUpdate
            Public Overridable Property BillingAddress As NAVAddressUpdate
            Public Overridable Property ShippingAddress As NAVAddressUpdate
            Public Overridable Property GovernmentId As String
            Public Overridable Property TermsAgreement As NAVTermsUpdate
            Public Overridable Property ElectronicAgreement As NAVTermsUpdate
            Public Overridable Property AgentId As String
            Public Overridable Property KitNumber As String
            Public Overridable Property KitPrice As Nullable(Of Decimal)
            Public Overridable Property PaymentMethod As String
            Public Overridable Property TaxAmount As Nullable(Of Decimal)
            Public Overridable Property DonationAmount As Nullable(Of Decimal)
            Public Overridable Property PublicityTag As String
            Public Overridable Property EStoreUrl As String
            Public Overridable Property ApptYYYYCC As String
            Public Overridable Property ApptHHMMSS As String
            Public Overridable Property ApptYYYYMMDD As String
            Public Overridable Property PrivacyPolicyAgreement As NAVTermsUpdate
            Public Overridable Property WebsiteTermsOfUseAgreement As NAVTermsUpdate
            Public Overridable Property AgeVerificationAgreement As NAVTermsUpdate
            Public Overridable Property CASLStatementAgreement As NAVCASLTermsUpdate
        End Class

        Public Partial Class LeadUpgradeResponse
            Public Overridable Property ResponseStatus As ResponseStatus
        End Class

        Public Partial Class NAVAddressUpdate
            Public Overridable Property FirstName As String
            Public Overridable Property LastName As String
            Public Overridable Property AddressLine1 As String
            Public Overridable Property AddressLine2 As String
            Public Overridable Property AddressLine3 As String
            Public Overridable Property AddressLine4 As String
            Public Overridable Property AddressLine5 As String
            Public Overridable Property City As String
            Public Overridable Property StateCode As String
            Public Overridable Property PostalCode As String
            Public Overridable Property CountryCode As String
        End Class

        Public Partial Class NAVCASLTermsUpdate
            Public Overridable Property Agree As String
            Public Overridable Property [Date] As Date
        End Class

        Public Partial Class NAVPhoneUpdate
            Public Overridable Property Number As String
            Public Overridable Property Extension As String
            Public Overridable Property CodeIdPhoneType As String
            Public Overridable Property CountryCode As String
        End Class

        Public Partial Class NAVTermsUpdate
            Public Overridable Property Version As String
            Public Overridable Property [Date] As Date
        End Class
    End Namespace
End Namespace

VB.NET LeadUpgrade DTOs

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 /upgrade-lead HTTP/1.1 
Host: extensions.avon.ca 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<LeadUpgrade xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/NAV.ServiceModel">
  <AdditionalPhone>
    <CodeIdPhoneType>String</CodeIdPhoneType>
    <CountryCode>String</CountryCode>
    <Extension>String</Extension>
    <Number>String</Number>
  </AdditionalPhone>
  <AgeVerificationAgreement>
    <Date>0001-01-01T00:00:00</Date>
    <Version>String</Version>
  </AgeVerificationAgreement>
  <AgentId>String</AgentId>
  <ApptHHMMSS>String</ApptHHMMSS>
  <ApptYYYYCC>String</ApptYYYYCC>
  <ApptYYYYMMDD>String</ApptYYYYMMDD>
  <BeeNumber>0</BeeNumber>
  <BillingAddress>
    <AddressLine1>String</AddressLine1>
    <AddressLine2>String</AddressLine2>
    <AddressLine3>String</AddressLine3>
    <AddressLine4>String</AddressLine4>
    <AddressLine5>String</AddressLine5>
    <City>String</City>
    <CountryCode>String</CountryCode>
    <FirstName>String</FirstName>
    <LastName>String</LastName>
    <PostalCode>String</PostalCode>
    <StateCode>String</StateCode>
  </BillingAddress>
  <BirthDate>0001-01-01T00:00:00</BirthDate>
  <CASLStatementAgreement>
    <Agree>String</Agree>
    <Date>0001-01-01T00:00:00</Date>
  </CASLStatementAgreement>
  <DonationAmount>0</DonationAmount>
  <EStoreUrl>String</EStoreUrl>
  <ElectronicAgreement>
    <Date>0001-01-01T00:00:00</Date>
    <Version>String</Version>
  </ElectronicAgreement>
  <EmailAddress>String</EmailAddress>
  <GovernmentId>String</GovernmentId>
  <KitNumber>String</KitNumber>
  <KitPrice>0</KitPrice>
  <Language>String</Language>
  <MentorBeeNumber>0</MentorBeeNumber>
  <PaymentMethod>String</PaymentMethod>
  <PrimaryPhone>
    <CodeIdPhoneType>String</CodeIdPhoneType>
    <CountryCode>String</CountryCode>
    <Extension>String</Extension>
    <Number>String</Number>
  </PrimaryPhone>
  <PrivacyPolicyAgreement>
    <Date>0001-01-01T00:00:00</Date>
    <Version>String</Version>
  </PrivacyPolicyAgreement>
  <PublicityTag>String</PublicityTag>
  <ShippingAddress>
    <AddressLine1>String</AddressLine1>
    <AddressLine2>String</AddressLine2>
    <AddressLine3>String</AddressLine3>
    <AddressLine4>String</AddressLine4>
    <AddressLine5>String</AddressLine5>
    <City>String</City>
    <CountryCode>String</CountryCode>
    <FirstName>String</FirstName>
    <LastName>String</LastName>
    <PostalCode>String</PostalCode>
    <StateCode>String</StateCode>
  </ShippingAddress>
  <TaxAmount>0</TaxAmount>
  <TermsAgreement>
    <Date>0001-01-01T00:00:00</Date>
    <Version>String</Version>
  </TermsAgreement>
  <WebsiteTermsOfUseAgreement>
    <Date>0001-01-01T00:00:00</Date>
    <Version>String</Version>
  </WebsiteTermsOfUseAgreement>
</LeadUpgrade>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<LeadUpgradeResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/NAV.ServiceModel">
  <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>
</LeadUpgradeResponse>