2011-02-18 95 views
0

在我的项目中,我在Authorize.net(CIM)中为每个用户注册创建了客户资料(不是付款资料),我已成功实施。但我必须动态删除这些客户资料(不是付款资料),即当网站管理员从此项目中删除每个用户时,必须从Authorize.net商家帐户中删除客户资料。Authorize.net CIM - 如何从Authorize.net中删除客户资料CIM

请大家帮帮我!!!!

回答

2

按照该Authorize.Net CIM XML Guide使用deleteCustomerProfileResponse API调用57页:

此功能用于与 一起删除 现有客户的个人资料相关联的所有客户付款 型材和客户发货 地址。

<?xml version="1.0" encoding="utf-8"?> 
<deleteCustomerProfileRequest xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd"> 
    <merchantAuthentication> 
    <name>YourUserLogin</name> 
    <transactionKey>YourTranKey</transactionKey> 
    </merchantAuthentication> 
    <customerProfileId>10000</customerProfileId> 
</deleteCustomerProfileRequest> 
+0

感谢您的答复..,我如何获得“customerProfileId”,因为我正在创建客户资料,所以在创建个人资料时我只传递了MerchantCustomerId。我已在Authorize.net CIM帐户中检查过这些配置文件,每个配置文件有两个ID,accountID(MerchantCustomerId)和profileID,我只传递MerchantCustomerId,所以我如何动态获取profileID? – user588575 2011-02-18 08:07:16

0

好,必须有一个会删除客户信息ID的功能,但如果你想删除的客户付款资料,然后在C#中使用此方法

public string DeleteCustPmtProfId(Int64 custProfID, Int64 custPmtProfID) 
{ 
    CustomerProfileWS.DeleteCustomerPaymentProfileResponseType response = SoapAPIUtilities.Service.DeleteCustomerPaymentProfile(SoapAPIUtilities.MerchantAuthentication, custProfID, custPmtProfID); 
    for (int i = 0; i < response.messages.Length; i++) 
    { 
     lblStatus.Text = lblStatus.Text + "<br/>Message: " + response.messages[i].text + "<br/>Response Code: " + response.resultCode + "<br/>"; 
     }  

    } 
相关问题