SignupCustomer 服务操作 - 客户管理

创建新的客户和帐户。

通常,你必须是具有聚合器 凭据 的用户才能调用此操作。 在这种情况下,操作会创建汇总到聚合器付款方式的新客户和帐户。 广告商帐户对象必须包含帐户名称、用于结算帐户的货币类型,并且付款方式标识符必须设置为 null。 该操作将生成发票帐户,并将付款方式标识符设置为与聚合器的发票关联的标识符。 你将被开具发票,用于支付你管理的客户产生的所有费用。

注意

代理客户在代表客户创建帐户试点 (GetCustomerPilotFeatures 返回 793) 可以代表客户注册新客户,并选择性地链接到新帐户作为代理。 在这种情况下,将发送 UserInvitation ,客户端必须通过Microsoft广告 UI 完成注册步骤,例如接受条款和条件。

注意

已关闭的统一智能市场活动试点的客户可以使用统一智能市场活动帐户注册新客户。 (可选)他们可以作为代理链接到新帐户。 超级管理员是通过设置 UserIdUserInvitation 元素来预配的

注意

无缝设置客户端帐户和 PI 试点中的客户可以使用帐户注册新客户,并同时创建管理员用户。 通过设置 User 元素来预配管理员用户。 客户必须通过Microsoft广告激活客户页面上的Microsoft广告 UI 完成注册步骤。

请求元素

SignupCustomerRequest 对象定义服务操作请求的正文标头元素。 元素的顺序必须与 请求 SOAP 中所示的顺序相同。

注意

除非下面另有说明,否则需要所有请求元素。

请求正文元素

元素 说明 数据类型
帐户 一个 广告客户帐户 ,用于指定客户主帐户的详细信息。

已关闭的统一智能市场活动试点的客户必须将 AccountMode 元素设置为“UnifiedSmart”。
AdvertiserAccount
客户 一个 Customer ,指定要添加的客户的详细信息。 客户
ParentCustomerId 将管理新子客户的聚合器或代理的客户标识符。

聚合器需要此元素,但在设置 UserInvitation 请求元素时忽略代理。 已关闭的统一智能市场活动试点的客户可以将新客户链接到父代理 ID,或将此元素留空。
long
用户 要创建的用户。 如果要注册新客户并同时创建新的管理员用户,则可以实现此元素。

新客户注册后,新创建的管理员用户必须通过Microsoft广告激活客户页面上的 Microsoft Advertising UI 完成注册步骤。 URL 为 https://ads.microsoft.com/ActivateCustomer?cid={new_customer_Id}&aid={new_account_Id},其中new_customer_Idnew_account_Id是你在 SignupCustomerResponse 中获取的 ID。

User 元素中的 AuthenticationToken 是 OAuth 访问令牌,表示将在注册期间创建的新管理员用户的凭据。

无缝设置客户端帐户和 PI 试点中的客户必须设置一个或多个 UserIdUserInvitationUser

User 对象中的必填字段为 ContactInfo.EmailName.FirstNameName.LastNameAuthenticationToken
用户
UserID 将在新客户中添加为超级管理员的现有用户的标识符。

此元素仅适用于封闭式统一智能市场活动试点中的客户。 必须设置一个或多个 UserIdUserInvitation 元素。
long
UserInvitation 如果要代表客户注册新客户并选择性地以代理身份链接到新帐户,则发送的用户邀请。

客户端超级管理员用户必须通过Microsoft广告 UI 完成注册步骤,例如接受条款和条件。

对于代表客户创建帐户试点中的代理客户,此元素是可选的。

关闭的统一智能市场活动试点的客户必须设置一个或多个 UserIdUserInvitation 元素。
UserInvitation

请求标头元素

元素 说明 数据类型
AuthenticationToken OAuth 访问令牌,表示有权Microsoft广告帐户的用户的凭据。

有关详细信息,请参阅 使用 OAuth 进行身份验证
string
DeveloperToken 用于访问必应广告 API 的开发人员令牌。

有关详细信息,请参阅 获取开发人员令牌
string
Password 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string
UserName 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string

响应元素

SignupCustomerResponse 对象定义服务操作响应的正文标头元素。 元素的返回顺序与 响应 SOAP 中所示的顺序相同。

响应正文元素

元素 说明 数据类型
AccountId 与请求中指定的新帐户对应的系统生成的帐户标识符。

将此标识符用于需要 AccountId 正文元素和 CustomerAccountId SOAP 标头元素的操作请求。
long
AccountNumber 系统生成的帐号,用于标识Microsoft广告 Web 应用程序中的帐户。

帐户号的格式为 xxxxxxxx,其中 xxxxxxxx 是任意 8 个字母数字字符的系列。
string
CreateTime 添加帐户的日期和时间。 日期和时间值反映服务器的日期和时间,而不是客户端。 有关日期和时间格式的信息,请参阅 基元 XML 数据类型中的 dateTime 条目。 dateTime
CustomerId 与请求中指定的新客户对应的系统生成的客户标识符。

将此标识符用于需要 CustomerId SOAP 标头元素的操作请求。
long
CustomerNumber 系统生成的客户编号,用于Microsoft广告 Web 应用程序。

客户编号的格式为 xxxxxxxxxx,其中 xxxxxxxxxx 是任意 10 个字母数字字符的系列。
string

响应标头元素

元素 说明 数据类型
跟踪 ID 包含 API 调用详细信息的日志条目的标识符。 string

请求 SOAP

此模板由一个工具生成,用于显示 SOAP 请求的正文标头元素的顺序。 有关可用于此服务操作的支持类型,请参阅上面的 请求正文元素 参考。

<s:Envelope xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
  <s:Header xmlns="https://bingads.microsoft.com/Customer/v13">
    <Action mustUnderstand="1">SignupCustomer</Action>
    <AuthenticationToken i:nil="false">ValueHere</AuthenticationToken>
    <DeveloperToken i:nil="false">ValueHere</DeveloperToken>
  </s:Header>
  <s:Body>
    <SignupCustomerRequest xmlns="https://bingads.microsoft.com/Customer/v13">
      <Customer xmlns:e95="https://bingads.microsoft.com/Customer/v13/Entities" i:nil="false">
        <e95:CustomerFinancialStatus i:nil="false">ValueHere</e95:CustomerFinancialStatus>
        <e95:Id i:nil="false">ValueHere</e95:Id>
        <e95:Industry i:nil="false">ValueHere</e95:Industry>
        <e95:LastModifiedByUserId i:nil="false">ValueHere</e95:LastModifiedByUserId>
        <e95:LastModifiedTime i:nil="false">ValueHere</e95:LastModifiedTime>
        <e95:MarketCountry i:nil="false">ValueHere</e95:MarketCountry>
        <e95:ForwardCompatibilityMap xmlns:e96="http://schemas.datacontract.org/2004/07/System.Collections.Generic" i:nil="false">
          <e96:KeyValuePairOfstringstring>
            <e96:key i:nil="false">ValueHere</e96:key>
            <e96:value i:nil="false">ValueHere</e96:value>
          </e96:KeyValuePairOfstringstring>
        </e95:ForwardCompatibilityMap>
        <e95:MarketLanguage i:nil="false">ValueHere</e95:MarketLanguage>
        <e95:Name i:nil="false">ValueHere</e95:Name>
        <e95:ServiceLevel i:nil="false">ValueHere</e95:ServiceLevel>
        <e95:CustomerLifeCycleStatus i:nil="false">ValueHere</e95:CustomerLifeCycleStatus>
        <e95:TimeStamp i:nil="false">ValueHere</e95:TimeStamp>
        <e95:Number i:nil="false">ValueHere</e95:Number>
        <e95:CustomerAddress i:nil="false">
          <e95:City i:nil="false">ValueHere</e95:City>
          <e95:CountryCode i:nil="false">ValueHere</e95:CountryCode>
          <e95:Id i:nil="false">ValueHere</e95:Id>
          <e95:Line1 i:nil="false">ValueHere</e95:Line1>
          <e95:Line2 i:nil="false">ValueHere</e95:Line2>
          <e95:Line3 i:nil="false">ValueHere</e95:Line3>
          <e95:Line4 i:nil="false">ValueHere</e95:Line4>
          <e95:PostalCode i:nil="false">ValueHere</e95:PostalCode>
          <e95:StateOrProvince i:nil="false">ValueHere</e95:StateOrProvince>
          <e95:TimeStamp i:nil="false">ValueHere</e95:TimeStamp>
          <e95:BusinessName i:nil="false">ValueHere</e95:BusinessName>
        </e95:CustomerAddress>
      </Customer>
      <Account xmlns:e97="https://bingads.microsoft.com/Customer/v13/Entities" i:nil="false">
        <e97:BillToCustomerId i:nil="false">ValueHere</e97:BillToCustomerId>
        <e97:CurrencyCode i:nil="false">ValueHere</e97:CurrencyCode>
        <e97:AccountFinancialStatus i:nil="false">ValueHere</e97:AccountFinancialStatus>
        <e97:Id i:nil="false">ValueHere</e97:Id>
        <e97:Language i:nil="false">ValueHere</e97:Language>
        <e97:LastModifiedByUserId i:nil="false">ValueHere</e97:LastModifiedByUserId>
        <e97:LastModifiedTime i:nil="false">ValueHere</e97:LastModifiedTime>
        <e97:Name i:nil="false">ValueHere</e97:Name>
        <e97:Number i:nil="false">ValueHere</e97:Number>
        <e97:ParentCustomerId>ValueHere</e97:ParentCustomerId>
        <e97:PaymentMethodId i:nil="false">ValueHere</e97:PaymentMethodId>
        <e97:PaymentMethodType i:nil="false">ValueHere</e97:PaymentMethodType>
        <e97:PrimaryUserId i:nil="false">ValueHere</e97:PrimaryUserId>
        <e97:AccountLifeCycleStatus i:nil="false">ValueHere</e97:AccountLifeCycleStatus>
        <e97:TimeStamp i:nil="false">ValueHere</e97:TimeStamp>
        <e97:TimeZone i:nil="false">ValueHere</e97:TimeZone>
        <e97:PauseReason i:nil="false">ValueHere</e97:PauseReason>
        <e97:ForwardCompatibilityMap xmlns:e98="http://schemas.datacontract.org/2004/07/System.Collections.Generic" i:nil="false">
          <e98:KeyValuePairOfstringstring>
            <e98:key i:nil="false">ValueHere</e98:key>
            <e98:value i:nil="false">ValueHere</e98:value>
          </e98:KeyValuePairOfstringstring>
        </e97:ForwardCompatibilityMap>
        <e97:LinkedAgencies i:nil="false">
          <e97:CustomerInfo>
            <e97:Id i:nil="false">ValueHere</e97:Id>
            <e97:Name i:nil="false">ValueHere</e97:Name>
          </e97:CustomerInfo>
        </e97:LinkedAgencies>
        <e97:SalesHouseCustomerId i:nil="false">ValueHere</e97:SalesHouseCustomerId>
        <e97:TaxInformation xmlns:e99="http://schemas.datacontract.org/2004/07/System.Collections.Generic" i:nil="false">
          <e99:KeyValuePairOfstringstring>
            <e99:key i:nil="false">ValueHere</e99:key>
            <e99:value i:nil="false">ValueHere</e99:value>
          </e99:KeyValuePairOfstringstring>
        </e97:TaxInformation>
        <e97:BackUpPaymentInstrumentId i:nil="false">ValueHere</e97:BackUpPaymentInstrumentId>
        <e97:BillingThresholdAmount i:nil="false">ValueHere</e97:BillingThresholdAmount>
        <e97:BusinessAddress i:nil="false">
          <e97:City i:nil="false">ValueHere</e97:City>
          <e97:CountryCode i:nil="false">ValueHere</e97:CountryCode>
          <e97:Id i:nil="false">ValueHere</e97:Id>
          <e97:Line1 i:nil="false">ValueHere</e97:Line1>
          <e97:Line2 i:nil="false">ValueHere</e97:Line2>
          <e97:Line3 i:nil="false">ValueHere</e97:Line3>
          <e97:Line4 i:nil="false">ValueHere</e97:Line4>
          <e97:PostalCode i:nil="false">ValueHere</e97:PostalCode>
          <e97:StateOrProvince i:nil="false">ValueHere</e97:StateOrProvince>
          <e97:TimeStamp i:nil="false">ValueHere</e97:TimeStamp>
          <e97:BusinessName i:nil="false">ValueHere</e97:BusinessName>
        </e97:BusinessAddress>
        <e97:AutoTagType i:nil="false">ValueHere</e97:AutoTagType>
        <e97:SoldToPaymentInstrumentId i:nil="false">ValueHere</e97:SoldToPaymentInstrumentId>
        <e97:TaxCertificate i:nil="false">
          <e97:TaxCertificateBlobContainerName i:nil="false">ValueHere</e97:TaxCertificateBlobContainerName>
          <e97:TaxCertificates xmlns:e100="http://schemas.datacontract.org/2004/07/System.Collections.Generic" i:nil="false">
            <e100:KeyValuePairOfstringbase64Binary>
              <e100:key i:nil="false">ValueHere</e100:key>
              <e100:value i:nil="false">ValueHere</e100:value>
            </e100:KeyValuePairOfstringbase64Binary>
          </e97:TaxCertificates>
          <e97:Status i:nil="false">ValueHere</e97:Status>
        </e97:TaxCertificate>
        <e97:AccountMode i:nil="false">ValueHere</e97:AccountMode>
      </Account>
      <ParentCustomerId i:nil="false">ValueHere</ParentCustomerId>
      <UserInvitation xmlns:e101="https://bingads.microsoft.com/Customer/v13/Entities" i:nil="false">
        <e101:Id>ValueHere</e101:Id>
        <e101:FirstName i:nil="false">ValueHere</e101:FirstName>
        <e101:LastName i:nil="false">ValueHere</e101:LastName>
        <e101:Email i:nil="false">ValueHere</e101:Email>
        <e101:CustomerId>ValueHere</e101:CustomerId>
        <e101:RoleId>ValueHere</e101:RoleId>
        <e101:AccountIds i:nil="false" xmlns:a1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <a1:long>ValueHere</a1:long>
        </e101:AccountIds>
        <e101:ExpirationDate>ValueHere</e101:ExpirationDate>
        <e101:Lcid>ValueHere</e101:Lcid>
      </UserInvitation>
      <UserId i:nil="false">ValueHere</UserId>
      <User xmlns:e102="https://bingads.microsoft.com/Customer/v13/Entities" i:nil="false">
        <e102:ContactInfo i:nil="false">
          <e102:Address i:nil="false">
            <e102:City i:nil="false">ValueHere</e102:City>
            <e102:CountryCode i:nil="false">ValueHere</e102:CountryCode>
            <e102:Id i:nil="false">ValueHere</e102:Id>
            <e102:Line1 i:nil="false">ValueHere</e102:Line1>
            <e102:Line2 i:nil="false">ValueHere</e102:Line2>
            <e102:Line3 i:nil="false">ValueHere</e102:Line3>
            <e102:Line4 i:nil="false">ValueHere</e102:Line4>
            <e102:PostalCode i:nil="false">ValueHere</e102:PostalCode>
            <e102:StateOrProvince i:nil="false">ValueHere</e102:StateOrProvince>
            <e102:TimeStamp i:nil="false">ValueHere</e102:TimeStamp>
            <e102:BusinessName i:nil="false">ValueHere</e102:BusinessName>
          </e102:Address>
          <e102:ContactByPhone i:nil="false">ValueHere</e102:ContactByPhone>
          <e102:ContactByPostalMail i:nil="false">ValueHere</e102:ContactByPostalMail>
          <e102:Email i:nil="false">ValueHere</e102:Email>
          <e102:EmailFormat i:nil="false">ValueHere</e102:EmailFormat>
          <e102:Fax i:nil="false">ValueHere</e102:Fax>
          <e102:HomePhone i:nil="false">ValueHere</e102:HomePhone>
          <e102:Id i:nil="false">ValueHere</e102:Id>
          <e102:Mobile i:nil="false">ValueHere</e102:Mobile>
          <e102:Phone1 i:nil="false">ValueHere</e102:Phone1>
          <e102:Phone2 i:nil="false">ValueHere</e102:Phone2>
        </e102:ContactInfo>
        <e102:CustomerId i:nil="false">ValueHere</e102:CustomerId>
        <e102:Id i:nil="false">ValueHere</e102:Id>
        <e102:JobTitle i:nil="false">ValueHere</e102:JobTitle>
        <e102:LastModifiedByUserId i:nil="false">ValueHere</e102:LastModifiedByUserId>
        <e102:LastModifiedTime i:nil="false">ValueHere</e102:LastModifiedTime>
        <e102:Lcid i:nil="false">ValueHere</e102:Lcid>
        <e102:Name i:nil="false">
          <e102:FirstName i:nil="false">ValueHere</e102:FirstName>
          <e102:LastName i:nil="false">ValueHere</e102:LastName>
          <e102:MiddleInitial i:nil="false">ValueHere</e102:MiddleInitial>
        </e102:Name>
        <e102:Password i:nil="false">ValueHere</e102:Password>
        <e102:SecretAnswer i:nil="false">ValueHere</e102:SecretAnswer>
        <e102:SecretQuestion>ValueHere</e102:SecretQuestion>
        <e102:UserLifeCycleStatus i:nil="false">ValueHere</e102:UserLifeCycleStatus>
        <e102:TimeStamp i:nil="false">ValueHere</e102:TimeStamp>
        <e102:UserName i:nil="false">ValueHere</e102:UserName>
        <e102:ForwardCompatibilityMap xmlns:e103="http://schemas.datacontract.org/2004/07/System.Collections.Generic" i:nil="false">
          <e103:KeyValuePairOfstringstring>
            <e103:key i:nil="false">ValueHere</e103:key>
            <e103:value i:nil="false">ValueHere</e103:value>
          </e103:KeyValuePairOfstringstring>
        </e102:ForwardCompatibilityMap>
        <e102:AuthenticationToken i:nil="false">ValueHere</e102:AuthenticationToken>
      </User>
    </SignupCustomerRequest>
  </s:Body>
</s:Envelope>

响应 SOAP

此模板由一个工具生成,用于显示 SOAP 响应的 正文标头 元素的顺序。

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
  <s:Header xmlns="https://bingads.microsoft.com/Customer/v13">
    <TrackingId d3p1:nil="false" xmlns:d3p1="http://www.w3.org/2001/XMLSchema-instance">ValueHere</TrackingId>
  </s:Header>
  <s:Body>
    <SignupCustomerResponse xmlns="https://bingads.microsoft.com/Customer/v13">
      <CustomerId>ValueHere</CustomerId>
      <CustomerNumber d4p1:nil="false" xmlns:d4p1="http://www.w3.org/2001/XMLSchema-instance">ValueHere</CustomerNumber>
      <AccountId d4p1:nil="false" xmlns:d4p1="http://www.w3.org/2001/XMLSchema-instance">ValueHere</AccountId>
      <AccountNumber d4p1:nil="false" xmlns:d4p1="http://www.w3.org/2001/XMLSchema-instance">ValueHere</AccountNumber>
      <CreateTime>ValueHere</CreateTime>
    </SignupCustomerResponse>
  </s:Body>
</s:Envelope>

代码语法

示例语法可用于 必应广告 SDK。 有关更多示例,请参阅 必应广告 API 代码示例

public async Task<SignupCustomerResponse> SignupCustomerAsync(
	Customer customer,
	AdvertiserAccount account,
	long? parentCustomerId,
	UserInvitation userInvitation,
	long? userId,
	User user)
{
	var request = new SignupCustomerRequest
	{
		Customer = customer,
		Account = account,
		ParentCustomerId = parentCustomerId,
		UserInvitation = userInvitation,
		UserId = userId,
		User = user
	};

	return (await CustomerManagementService.CallAsync((s, r) => s.SignupCustomerAsync(r), request));
}
static SignupCustomerResponse signupCustomer(
	Customer customer,
	AdvertiserAccount account,
	java.lang.Long parentCustomerId,
	UserInvitation userInvitation,
	java.lang.Long userId,
	User user) throws RemoteException, Exception
{
	SignupCustomerRequest request = new SignupCustomerRequest();

	request.setCustomer(customer);
	request.setAccount(account);
	request.setParentCustomerId(parentCustomerId);
	request.setUserInvitation(userInvitation);
	request.setUserId(userId);
	request.setUser(user);

	return CustomerManagementService.getService().signupCustomer(request);
}
static function SignupCustomer(
	$customer,
	$account,
	$parentCustomerId,
	$userInvitation,
	$userId,
	$user)
{

	$GLOBALS['Proxy'] = $GLOBALS['CustomerManagementProxy'];

	$request = new SignupCustomerRequest();

	$request->Customer = $customer;
	$request->Account = $account;
	$request->ParentCustomerId = $parentCustomerId;
	$request->UserInvitation = $userInvitation;
	$request->UserId = $userId;
	$request->User = $user;

	return $GLOBALS['CustomerManagementProxy']->GetService()->SignupCustomer($request);
}
response=customermanagement_service.SignupCustomer(
	Customer=Customer,
	Account=Account,
	ParentCustomerId=ParentCustomerId,
	UserInvitation=UserInvitation,
	UserId=UserId,
	User=User)

要求

服务: CustomerManagementService.svc v13
命名空间: https://bingads.microsoft.com/Customer/v13

请求 URL

https://clientcenter.api.bingads.microsoft.com/CustomerManagement/v13/Customer/Signup

请求元素

SignupCustomerRequest 对象定义服务操作请求的正文标头元素。

注意

除非下面另有说明,否则需要所有请求元素。

请求正文元素

元素 说明 数据类型
帐户 一个 广告客户帐户 ,用于指定客户主帐户的详细信息。

已关闭的统一智能市场活动试点的客户必须将 AccountMode 元素设置为“UnifiedSmart”。
AdvertiserAccount
客户 一个 Customer ,指定要添加的客户的详细信息。 客户
ParentCustomerId 将管理新子客户的聚合器或代理的客户标识符。

聚合器需要此元素,但在设置 UserInvitation 请求元素时忽略代理。 已关闭的统一智能市场活动试点的客户可以将新客户链接到父代理 ID,或将此元素留空。
long
用户 要创建的用户。 如果要注册新客户并同时创建新的管理员用户,则可以实现此元素。

新客户注册后,新创建的管理员用户必须通过Microsoft广告激活客户页面上的 Microsoft Advertising UI 完成注册步骤。 URL 为 https://ads.microsoft.com/ActivateCustomer?cid={new_customer_Id}&aid={new_account_Id},其中new_customer_Idnew_account_Id是你在 SignupCustomerResponse 中获取的 ID。

User 元素中的 AuthenticationToken 是 OAuth 访问令牌,表示将在注册期间创建的新管理员用户的凭据。

无缝设置客户端帐户和 PI 试点中的客户必须设置一个或多个 UserIdUserInvitationUser

User 对象中的必填字段为 ContactInfo.EmailName.FirstNameName.LastNameAuthenticationToken
用户
UserID 将在新客户中添加为超级管理员的现有用户的标识符。

此元素仅适用于封闭式统一智能市场活动试点中的客户。 必须设置一个或多个 UserIdUserInvitation 元素。
long
UserInvitation 如果要代表客户注册新客户并选择性地以代理身份链接到新帐户,则发送的用户邀请。

客户端超级管理员用户必须通过Microsoft广告 UI 完成注册步骤,例如接受条款和条件。

对于代表客户创建帐户试点中的代理客户,此元素是可选的。

关闭的统一智能市场活动试点的客户必须设置一个或多个 UserIdUserInvitation 元素。
UserInvitation

请求标头元素

元素 说明 数据类型
Authorization OAuth 访问令牌,表示有权Microsoft广告帐户的用户的凭据。 请确保令牌的前缀为“持有者”,这是正确身份验证所必需的。

有关详细信息,请参阅 使用 OAuth 进行身份验证
string
DeveloperToken 用于访问必应广告 API 的开发人员令牌。

有关详细信息,请参阅 获取开发人员令牌
string
Password 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string
UserName 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string

响应元素

SignupCustomerResponse 对象定义服务操作响应的正文标头元素。 元素的返回顺序与 响应 JSON 中所示的顺序相同。

响应正文元素

元素 说明 数据类型
AccountId 与请求中指定的新帐户对应的系统生成的帐户标识符。

将此标识符用于需要 AccountId 正文元素和 CustomerAccountId SOAP 标头元素的操作请求。
long
AccountNumber 系统生成的帐号,用于标识Microsoft广告 Web 应用程序中的帐户。

帐户号的格式为 xxxxxxxx,其中 xxxxxxxx 是任意 8 个字母数字字符的系列。
string
CreateTime 添加帐户的日期和时间。 日期和时间值反映服务器的日期和时间,而不是客户端。 有关日期和时间格式的信息,请参阅 基元 XML 数据类型中的 dateTime 条目。 dateTime
CustomerId 与请求中指定的新客户对应的系统生成的客户标识符。

将此标识符用于需要 CustomerId SOAP 标头元素的操作请求。
long
CustomerNumber 系统生成的客户编号,用于Microsoft广告 Web 应用程序。

客户编号的格式为 xxxxxxxxxx,其中 xxxxxxxxxx 是任意 10 个字母数字字符的系列。
string

响应标头元素

元素 说明 数据类型
跟踪 ID 包含 API 调用详细信息的日志条目的标识符。 string

请求 JSON

此模板由显示 JSON 请求的 正文标头 元素的工具生成。 有关可用于此服务操作的支持类型,请参阅上面的 请求正文元素 参考。

{
  "Customer": {
    "CustomerAddress": {
      "BusinessName": "ValueHere",
      "City": "ValueHere",
      "CountryCode": "ValueHere",
      "Id": "LongValueHere",
      "Line1": "ValueHere",
      "Line2": "ValueHere",
      "Line3": "ValueHere",
      "Line4": "ValueHere",
      "PostalCode": "ValueHere",
      "StateOrProvince": "ValueHere",
      "TimeStamp": "ValueHere"
    },
    "CustomerFinancialStatus": "ValueHere",
    "CustomerLifeCycleStatus": "ValueHere",
    "ForwardCompatibilityMap": [
      {
        "key": "ValueHere",
        "value": "ValueHere"
      }
    ],
    "Id": "LongValueHere",
    "Industry": "ValueHere",
    "LastModifiedByUserId": "LongValueHere",
    "LastModifiedTime": "ValueHere",
    "MarketCountry": "ValueHere",
    "MarketLanguage": "ValueHere",
    "Name": "ValueHere",
    "Number": "ValueHere",
    "ServiceLevel": "ValueHere",
    "TimeStamp": "ValueHere"
  },
  "Account": {
    "AccountFinancialStatus": "ValueHere",
    "AccountLifeCycleStatus": "ValueHere",
    "AccountMode": "ValueHere",
    "AutoTagType": "ValueHere",
    "BackUpPaymentInstrumentId": "LongValueHere",
    "BillingThresholdAmount": DecimalValueHere,
    "BillToCustomerId": "LongValueHere",
    "BusinessAddress": {
      "BusinessName": "ValueHere",
      "City": "ValueHere",
      "CountryCode": "ValueHere",
      "Id": "LongValueHere",
      "Line1": "ValueHere",
      "Line2": "ValueHere",
      "Line3": "ValueHere",
      "Line4": "ValueHere",
      "PostalCode": "ValueHere",
      "StateOrProvince": "ValueHere",
      "TimeStamp": "ValueHere"
    },
    "CurrencyCode": "ValueHere",
    "ForwardCompatibilityMap": [
      {
        "key": "ValueHere",
        "value": "ValueHere"
      }
    ],
    "Id": "LongValueHere",
    "Language": "ValueHere",
    "LastModifiedByUserId": "LongValueHere",
    "LastModifiedTime": "ValueHere",
    "LinkedAgencies": [
      {
        "Id": "LongValueHere",
        "Name": "ValueHere"
      }
    ],
    "Name": "ValueHere",
    "Number": "ValueHere",
    "ParentCustomerId": "LongValueHere",
    "PauseReason": "ValueHere",
    "PaymentMethodId": "LongValueHere",
    "PaymentMethodType": "ValueHere",
    "PrimaryUserId": "LongValueHere",
    "SalesHouseCustomerId": "LongValueHere",
    "SoldToPaymentInstrumentId": "LongValueHere",
    "TaxCertificate": {
      "Status": "ValueHere",
      "TaxCertificateBlobContainerName": "ValueHere",
      "TaxCertificates": [
        {
          "key": "ValueHere",
          "value": "ValueHere"
        }
      ]
    },
    "TaxInformation": [
      {
        "key": "ValueHere",
        "value": "ValueHere"
      }
    ],
    "TimeStamp": "ValueHere",
    "TimeZone": "ValueHere"
  },
  "ParentCustomerId": "LongValueHere",
  "UserInvitation": {
    "AccountIds": [
      "LongValueHere"
    ],
    "CustomerId": "LongValueHere",
    "Email": "ValueHere",
    "ExpirationDate": "ValueHere",
    "FirstName": "ValueHere",
    "Id": "LongValueHere",
    "LastName": "ValueHere",
    "Lcid": "ValueHere",
    "RoleId": IntValueHere
  },
  "UserId": "LongValueHere",
  "User": {
    "AuthenticationToken": "ValueHere",
    "ContactInfo": {
      "Address": {
        "BusinessName": "ValueHere",
        "City": "ValueHere",
        "CountryCode": "ValueHere",
        "Id": "LongValueHere",
        "Line1": "ValueHere",
        "Line2": "ValueHere",
        "Line3": "ValueHere",
        "Line4": "ValueHere",
        "PostalCode": "ValueHere",
        "StateOrProvince": "ValueHere",
        "TimeStamp": "ValueHere"
      },
      "ContactByPhone": "ValueHere",
      "ContactByPostalMail": "ValueHere",
      "Email": "ValueHere",
      "EmailFormat": "ValueHere",
      "Fax": "ValueHere",
      "HomePhone": "ValueHere",
      "Id": "LongValueHere",
      "Mobile": "ValueHere",
      "Phone1": "ValueHere",
      "Phone2": "ValueHere"
    },
    "CustomerId": "LongValueHere",
    "ForwardCompatibilityMap": [
      {
        "key": "ValueHere",
        "value": "ValueHere"
      }
    ],
    "Id": "LongValueHere",
    "JobTitle": "ValueHere",
    "LastModifiedByUserId": "LongValueHere",
    "LastModifiedTime": "ValueHere",
    "Lcid": "ValueHere",
    "Name": {
      "FirstName": "ValueHere",
      "LastName": "ValueHere",
      "MiddleInitial": "ValueHere"
    },
    "Password": "ValueHere",
    "SecretAnswer": "ValueHere",
    "SecretQuestion": "ValueHere",
    "TimeStamp": "ValueHere",
    "UserLifeCycleStatus": "ValueHere",
    "UserName": "ValueHere"
  }
}

响应 JSON

此模板由一个工具生成,用于显示 JSON 响应的 正文标头 元素。

{
  "CustomerId": "LongValueHere",
  "CustomerNumber": "ValueHere",
  "AccountId": "LongValueHere",
  "AccountNumber": "ValueHere",
  "CreateTime": "ValueHere"
}

代码语法

若要通过 SDK 调用 REST API,需要将 SDK 升级到特定版本并配置系统参数。示例语法可用于 必应广告 SDK。 有关更多示例,请参阅 必应广告 API 代码示例

public async Task<SignupCustomerResponse> SignupCustomerAsync(
	Customer customer,
	AdvertiserAccount account,
	long? parentCustomerId,
	UserInvitation userInvitation,
	long? userId,
	User user)
{
	var request = new SignupCustomerRequest
	{
		Customer = customer,
		Account = account,
		ParentCustomerId = parentCustomerId,
		UserInvitation = userInvitation,
		UserId = userId,
		User = user
	};

	return (await CustomerManagementService.CallAsync((s, r) => s.SignupCustomerAsync(r), request));
}
static SignupCustomerResponse signupCustomer(
	Customer customer,
	AdvertiserAccount account,
	java.lang.Long parentCustomerId,
	UserInvitation userInvitation,
	java.lang.Long userId,
	User user) throws RemoteException, Exception
{
	SignupCustomerRequest request = new SignupCustomerRequest();

	request.setCustomer(customer);
	request.setAccount(account);
	request.setParentCustomerId(parentCustomerId);
	request.setUserInvitation(userInvitation);
	request.setUserId(userId);
	request.setUser(user);

	return CustomerManagementService.getService().signupCustomer(request);
}
static function SignupCustomer(
	$customer,
	$account,
	$parentCustomerId,
	$userInvitation,
	$userId,
	$user)
{

	$GLOBALS['Proxy'] = $GLOBALS['CustomerManagementProxy'];

	$request = new SignupCustomerRequest();

	$request->Customer = $customer;
	$request->Account = $account;
	$request->ParentCustomerId = $parentCustomerId;
	$request->UserInvitation = $userInvitation;
	$request->UserId = $userId;
	$request->User = $user;

	return $GLOBALS['CustomerManagementProxy']->GetService()->SignupCustomer($request);
}
response=customermanagement_service.SignupCustomer(
	Customer=Customer,
	Account=Account,
	ParentCustomerId=ParentCustomerId,
	UserInvitation=UserInvitation,
	UserId=UserId,
	User=User)