canProcessOrderWithPaymentResult
The canProcessOrderWithPaymentResult API is used by the ACQP app to check if an external redirect URL can be processed by the SDK. In case the redirect URL can be processed by the SDK, you need to call the processOrderWithPaymentResult API to resolve the URL to obtain the payment result.
Note: Currently, only the Alipay app returns the payment result in a redirect URL.
Method signature
copy
@Interface AlipayPlusClient:NSObject
- (BOOL)canProcessOrderWithPaymentResult:(NSURL *)resultUrl;
@end
Request parameters
Name | Type | Length | Description | Required |
resultUrl | NSURL | / | The redirect URL that is returned by an external party. | M |
Response parameters
N/A
Sample
copy
- (BOOL)application:(UIApplication *)app openURL:(NSURL *)url options:(NSDictionary<UIApplicationOpenURLOptionsKey,id> *)options {
if ([[AlipayPlusClient shared] canProcessOrderWithPaymentResult:url]) {
[[AlipayPlusClient shared] processOrderWithPaymentResult:url];
}
return YES;
}