【发布时间】:2017-11-08 07:32:28
【问题描述】:
我想以条带方式创建自定义帐户,以便我可以通过自己的平台对其进行管理。我在条纹上创建了平台。为此,我正在使用 stripe.Net。我已经使用此代码创建了几个帐户:
var account = new StripeAccountCreateOptions
{
Email = customer.Email,
Managed = true,
Country = customer.Country.ToString(),
BusinessName = customer.BussinessName,
BusinessUrl = customer.BussinessUrl,
LegalEntity = new StripeAccountLegalEntityOptions()
{
FirstName = "imran",
LastName = "shahid",
BirthDay = 20,
BirthMonth = 3,
BirthYear = 1993,
Type = "individual",
AddressCity = "new york",
AddressPostalCode = "12345",
AddressLine1 = "kalma chok",
AddressState = "new york",
SSNLast4 = "5467",
PersonalIdNumber = "127.0.0.1"
},
TosAcceptanceDate = DateTime.Today,
TosAcceptanceIp = "127.0.0.1",
ExternalCardAccount = new StripeAccountCardOptions()
{
AddressCity = "abc",
AddressCountry = "US",
Currency = "usd",
Number = "4000056655665556",
ExpirationYear = "2020",
ExpirationMonth = "03",
Cvc = "123"
},
};
var accountService = new StripeAccountService();
StripeAccount response = accountService.Create(account);
但是当我访问网站时,所有帐户都未经验证。
对于付款,我正在使用此代码
var myCharge = new StripeChargeCreateOptions
{
Amount = 1000,
Currency = "usd",
Description = "Charge it like it's hot",
SourceTokenOrExistingSourceId = "*SourceTokenOrExistingSourceId*",
ApplicationFee = 25,
Capture = true
};
var chargeService = new StripeChargeService();
StripeCharge stripeCharge = chargeService.Create(myCharge);
如何获取SourceTokenOrExistingSourceId?实际上,我想从一位客户那里扣除钱并将其转入我的帐户,然后我还想将钱从我的帐户转入客户帐户。为此,我没有得到适当的教程或任何示例代码。你能帮我吗?我只想做三件事
1) 创建经过验证的客户帐户
2) 向客户收费(自定义帐户)
3) 向客户转账(自定义账户)
【问题讨论】:
标签: c# asp.net stripe-payments stripe.net