简体   繁体   English

适用于混合移动应用程序的Paypal API

[英]Paypal api for hybrid mobile app

I am in big dilemma for last few days while studying paypal API for creating an HTML5 based hybrid app that needs to use paypal api for carrying out some transactions. 最近几天,我在研究Paypal API来创建基于HTML5的混合应用程序时遇到了很大的难题,该应用程序需要使用paypal api来执行一些交易。

What I need is I want to use some Paypal API in HTML5 based mobile app, that will finally get bundled into some native app, say for example .apk files. 我需要的是我想在基于HTML5的移动应用程序中使用一些Paypal API,最终将它们捆绑到某些本机应用程序中,例如.apk文件。

The problem is : 问题是 :

  1. I have not found a single link that explains that if the paypal provides any api for hybrid app. 我没有找到一个单一的链接来说明该支付宝是否为混合应用程序提供任何api。

  2. I have read their new buttons, name value api, etc. Will any of these will work in my current application when they get deployed as an .apk for android? 我已经阅读了它们的新按钮,名称值api等。当将它们部署为Android的.apk时,这些按钮中的任何一个都能在我的当前应用程序中运行吗? The thing that makes me worry is that paypal needs redirectURL, so what it will do incase of single page app? 让我担心的是,贝宝​​需要redirectURL,那么在单页面应用程序的情况下该怎么办?

Any links or references are welcome! 欢迎任何链接或参考!

I would highly suggest you try Cordova for your App. 我强烈建议您尝试将Cordova用于您的App。 It does HTML5 in an app format and works very well. 它以应用程序格式执行HTML5,并且效果很好。

I don't know that you would want to make API calls but your HTML buttons would definitely work. 我不知道您想进行API调用,但您的HTML按钮肯定可以工作。 Paypal also has a plugin that would work as well (Cordova is also called Phonegap). 贝宝(Paypal)也有一个可以正常使用的插件 (科多瓦也称为Phonegap)。

PhoneGap/Cordova will be my recommendation for any hybrid mobile apps. 对于任何混合移动应用程序,PhoneGap / Cordova都是我的推荐。

PayPal has an official plugin for PhoneGap with Android SDK. 贝宝(PayPal)具有带Android SDK的PhoneGap官方插件。

Refer https://github.com/paypal/PayPal-Android-SDK-PhoneGap 请参阅https://github.com/paypal/PayPal-Android-SDK-PhoneGap

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM