GetSubCustomer

Description

This method allows you to view all of the stored data for a particular sub-customer.

This method requires the use of the customerId and subCustomerId or subCustomerInternalId.

Syntax

SubCustomer GetSubCustomer(SecurityToken securityToken, string customerId, string subCustomerId, string subCustomerInternalId);

Arguments

Type

Name

Description

SecurityToken](/docs/securitytoken)

securityToken

Merchant security token: used to identify merchant and validate transaction. (required)

string

customerId

Customer ID. (required)

string

subCustomerId

Sub-customer ID. (optional)

string

subCustomerInternalId

Unique sub-customer ID assigned by the internal system. (required)

Return Value

Type

Description

SubCustomer

Returns sub-customer information, such as customer ID, merchant-assigned sub-customer ID, billing address, receipt settings, recurring billing settings, and other pertinent information.

Examples

var client = new EBizSOAP.IeBizServiceClient();
EBizSOAP.SecurityToken securityToken = new EBizSOAP.SecurityToken();
EBizSOAP.SubCustomer subCustomer = new EBizSOAP.SubCustomer();
securityToken.UserId = "";
securityToken.SecurityId = "1dc496d1-90b4-4a38-ad78-28a795af78e9";
securityToken.Password = "";
EBizSOAP.SubCustomer SubCustomer= client.GetSubCustomer(securityToken, "123456", "s01", "");
Console.WriteLine(SubCustomer.SubCustomerId);
Console.WriteLine(SubCustomer.SubCustomerInternalId);
Console.WriteLine(SubCustomer.FirstName);
Console.WriteLine(SubCustomer.LastName);
Request using subCustomerInternalId

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ebiz="http://eBizCharge.ServiceModel.SOAP">
   <soapenv:Header/>
   <soapenv:Body>
      <ebiz:GetSubCustomer>
         <ebiz:securityToken>
            <ebiz:SecurityId>1dc496d1-90b4-4a38-ad78-28a795af78e9</ebiz:SecurityId>
            <ebiz:UserId>userid</ebiz:UserId>
            <ebiz:Password>password</ebiz:Password>
         </ebiz:securityToken>
         <ebiz:customerId></ebiz:customerId>
         <ebiz:subCustomerId></ebiz:subCustomerId>
         <ebiz:subCustomerInternalId>1afd2435-dafe-4529-94f6-7fd458af6958</ebiz:subCustomerInternalId>
      </ebiz:GetSubCustomer>
   </soapenv:Body>
</soapenv:Envelope>

OR Request using customerId and subCustomerId

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ebiz="http://eBizCharge.ServiceModel.SOAP">
   <soapenv:Header/>
   <soapenv:Body>
      <ebiz:GetSubCustomer>
         <ebiz:securityToken>
            <ebiz:SecurityId>1dc496d1-90b4-4a38-ad78-28a795af78e9</ebiz:SecurityId>
            <ebiz:UserId>userid</ebiz:UserId>
            <ebiz:Password>password</ebiz:Password>
         </ebiz:securityToken>
         <ebiz:customerId>mm-0011-03</ebiz:customerId>
         <ebiz:subCustomerId>mm-0011-03[4]</ebiz:subCustomerId>
         <ebiz:subCustomerInternalId></ebiz:subCustomerInternalId>
      </ebiz:GetSubCustomer>
   </soapenv:Body>
</soapenv:Envelope>


Response:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
   <s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      <GetSubCustomerResponse xmlns="http://eBizCharge.ServiceModel.SOAP">
         <GetSubCustomerResult>
            <CustomerInternalId/>
            <CustomerId>mm-0011-03</CustomerId>
            <SubCustomerId>mm-0011-03[4]</SubCustomerId>
            <SubCustomerInternalId>1afd2435-dafe-4529-94f6-7fd458af6958</SubCustomerInternalId>
            <BillingAddress>
               <FirstName>Anthony</FirstName>
               <LastName>Kim</LastName>
               <CompanyName>CBS</CompanyName>
               <Address1>20 Pacifica</Address1>
               <Address2>Suite 1450</Address2>
               <City>Irvine</City>
               <State>CA</State>
               <ZipCode>92618</ZipCode>
            </BillingAddress>
            <FirstName>Anthony</FirstName>
            <LastName>Kim</LastName>
            <CompanyName>CBS</CompanyName>
            <Phone/>
            <CellPhone/>
            <Fax/>
            <Email>[email protected]</Email>
            <WebSite/>
         </GetSubCustomerResult>
      </GetSubCustomerResponse>
   </s:Body>
</s:Envelope>