[英]PayPal iOS SDK - Payment not available for apps with a Mobile SDK type of integration
[英]iOS Paypal Mobile SDK - Proof of Payment
我在我的應用程序中集成了適用於iOS的Paypal Mobile SDK。
在委托Methode completePayment中,我得到以下json:
CurrencyCode: EUR
Amount: 39.95
Short Description: Michaels Test
Intent: sale
Processable: Already processed
Display: €39.95
Confirmation: {
client = {
environment = mock;
"paypal_sdk_version" = "2.12.3";
platform = iOS;
"product_name" = "PayPal iOS SDK";
};
response = {
"create_time" = "2015-10-29T13:18:02Z";
id = "PAY-NONETWORKPAYIDEXAMPLE123";
intent = sale;
state = approved;
};
"response_type" = payment;
}
Details: (null)
Shipping Address: (null)
Invoice Number: (null)
Custom: (null)
Soft Descriptor: (null)
BN code: (null)
它說成功創建。 但是,當我在developer.paypal.com上查看我的儀表板時,我看不到任何交易。 對於環境,我使用paypal-sandbox。
在文檔中說我必須使用rest-api來驗證立即付款: https : //developer.paypal.com/docs/integration/mobile/verify-mobile-payment/
那么,我是否需要一個后端服務來驗證我從客戶那里創建的付款,或者我現在必須做什么?
Thx,邁克爾
在此處使用您的Sandbox帳戶登錄... Sandbox Paypal網站 。 您將可以在Paypal的沙箱網站上查看在“沙箱環境”上進行的交易。
查看確認消息,您正在以PayPalEnvironmentNoNetwork
模式運行您的應用程序。
/// Production (default): Normal, live environment. Real money gets moved.
/// This environment MUST be used for App Store submissions.
extern NSString *const PayPalEnvironmentProduction;
/// Sandbox: Uses the PayPal sandbox for transactions. Useful for development.
extern NSString *const PayPalEnvironmentSandbox;
/// NoNetwork: Mock mode. Does not submit transactions to PayPal. Fakes successful responses. Useful for unit tests.
extern NSString *const PayPalEnvironmentNoNetwork;
您需要在SandBox
環境中運行您的應用程序。 獲取YOUR_CLIENT_ID_FOR_SANDBOX
並使用它初始化PayPal
。
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
[PayPalMobile initializeWithClientIdsForEnvironments:@{PayPalEnvironmentSandbox : @"YOUR_CLIENT_ID_FOR_SANDBOX"}];
return YES;
}
然后,您將可以在上述鏈接的網站中查看交易。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.