How can i implement payment through payment with two receivers? - paypal

Working on Android Application which provides platform for users to sell and buy their used products. Below is the scenario of payment screen when User(buy) want to bought an item.
How can i do this payment with paypal adaptive payment. I found something Parallel payment api but in this api doing parallel payment form owner's account need same thing with dynamic customer account.Every thing needed in PHP to develop web service will be used in android application.
Thanks.

Adaptive Payments, specifically the Pay API. That is how you would do the split payment as either parallel or chained.
From mobile apps I typically build the web services on a server, so you can still write everything in PHP and just pass data to and from PayPal back to the app through the PHP service. Then you make simple serice requests to your own PHP script and have it just return a basic JSON response or whatever you want to work with in the mobile app.
There may be more direct ways to get it done, but that's what I've always done and it works well. Allows you to use your web server for more detailed logging, too.

Related

server side code for payment gateway integration with flutter

I'm trying to integrate a payment gateway like razorpay or stripe in my flutter app, and for any payment provider we need to generate a token using their API in the backend , but none of these payment providers have mentioned the code for the server side to generate tokens and how/where to deploy that server side code. Essentially I'm creating an ecommerce app and to process payments I can't find resources to implement the server side code for each cart order. Can anyone tell how to implement the server side code or some resource which could be useful?
Docs I have read:
https://pub.dev/packages/razorpay_flutter
https://razorpay.com/docs/payments/payment-gateway/flutter-integration/standard/build-integration#16-create-an-order-in-server
but none of these payment providers have mentioned the code for the server side to generate tokens and how/where to deploy that server side code
This is by design. Payment providers help you lower your PCI compliance burden by not touching raw card details. If you use frontend SDKs (like Stripe's Stripe.js + Elements UI library), they are an iframe that collects your end customer card details directly to their servers meaning your integration does not touch card details and does not have to do tons of paperwork on your own PCI compliance.
https://stripe.com/docs/security/guide
https://stripe.com/guides/pci-compliance
So you absolutely need to use their frontend SDKs to directly create a token from your webpage.
I can't find resources to implement the server side code for each cart order.
Once you have your token, you then send that to your server to create an order and (in Stripe's case) create and confirm a PaymentIntent. Though Stripe's recommended flow is a bit different - you create the PaymentIntent first and "confirm" it on your frontend: https://stripe.com/docs/payments/accept-a-payment
For razorpay integration (atleast as a payment gateway) you will be in need of a client and a server. As you say you have the client with you. After the user initiates the payment and completes it in the flutter client - the client has to send out an api request to the api server that can actually capture the payment with the hash comparisons.
I don't not much idea about Razorpay integration but for Stripe you can use Payment Intent API.
You can divide the process in 3 steps:
Send card details from Front-end, if it's a Stripe Customer then you can even use their default card.
Create a payment Intent in Backend, this will return a payment intent object with client_secret. You also might wanna save the payment intent id in DB.
Send this client_secret to Frontend, where you can use this client secret in Stripe.confirmCardPayment(client_secret).
Listen to webhook events to check on the payment status/progress. It's basically an open endpoint where stripe will make REST calls and provide you with details about your payment progress.
Here's a link to the docs mentioning this process. There was an even better doc/github link that I can't seem to find, it had the entire end-to-end happy process.
If this seems a bit complicated then you go with checkout API of Stripe. I've also attached a few youtube videos that might help ya in getting started.
Checkout API YT link
Payment Intent YT link

Best Paypal mobile integration option for Subscription services

I have a native mobile app in which I want users to subscribe for a monthly fee. I started by integrating with the native PayPal SDKs and use future payments, but in that case I'm in charge of processing the payments every month. I want a more automatic way where users approve their subscription and PayPal automatically posts the payments every month.
I have also started looking at Stripe, so if there is a solution using another library I would be glad to hear of that too.
(Disclaimer: I work for Stripe.)
Stripe does support recurring payments with the "subscriptions" feature. You can read more about it here:
https://stripe.com/docs/subscriptions
https://stripe.com/docs/guides/subscriptions
To implement this in a mobile app, you'd need to use the iOS SDK and/or the Android SDK. Both SDKs offer the same functionality: the ability to turn card information into a token, by exchanging the information directly between the user's device and Stripe's servers.
This way, the sensitive card information never hits your server, which greatly reduces the burden of PCI compliance. You can read more here: https://support.stripe.com/questions/do-i-need-to-be-pci-compliant-what-do-i-have-to-do. (This article talks about Stripe.js and Checkout, but the mobile SDKs serve the same purpose.)
Once a token has been created, you'd need to send it to an external server, where you would use it to create a customer object and a subscription, as explained in the subscriptions documentation I linked above.
The reason why this needs to be done on an external server and not in the app itself is because aside from the creation of card tokens, all other API requests need to be sent with your secret API key. You cannot embed or otherwise provide the secret API key to your app, as an attacker could extract it and use it for malicious purposes (they could refund past charges, use your account to test stolen card numbers, etc.).

Integrate Paypal Here with Openbravo POS

How can I integrate Paypal Here with Openbravo POS?
The workflow I'm looking for is:
Cashier selects card payment on Openbravo POS
Bill is automatically transferred to Paypal Here
Customer completes payment on Paypal Here
Confirmation is automatically transferred to Openbravo POS
I see there is an API for integrating iOS applications with Paypal Here, so this is certainly possible. It would be quite complicated to write an iOS application to do this; perhaps there's a simpler way?
I have now implemented my own system to do this. It consists of:
OpenBravoPOS scripting and a Java class to upload transaction details and wait for a response
A web application that receives the transaction details
A mobile web page that uses the Sideloader API to pass transaction details into Paypal Here
A callback on the web app that receives the transaction ID
This is working fine in a real shop. If you're interested in this solution, see my website.
To develop a fully-integrated solution, the PayPal Here SDKs for iOS and Android are now available on the PayPal Developer site:
https://developer.paypal.com/webapps/developer/docs/integration/mobile/pph-sdk-overview/
There is also a version for Windows 8.1+ in Beta, available upon request. You can email DL-PayPal-Here-SDK#ebay.com for help with any of these.

Payment Methods In iPhone App?

I have an iPhone app where I have a list of items to be sold. For the payment of these items, I have a web service on my sponsor's server that needs to be utilized by sending certain parameters such as amount, userid, discount coupons etc. So should I invoke this in a web view inside the application or should it be invoked in the web-browser? The sponsorer wants to show a message as payment successful or not in the application after everything is done. this information comes from the server itself. But if I invoke the browser i will not be able to track this information about payment successful or not? What should I do? Please help me with this
This is particularly interesting with regards to iOS as it gives app developers a fairly easy way to implement an alternative payment solution to the App Store, something that doesn’t infringe on Apple’s in-app purchasing policy if the goods being sold are physical not digital. It’s this scenario that Adyen is targeting.
As for the payment method itself, it accepts credit cards, PayPal and a range of other payments within mobile applications (native apps) and mobile websites. Of course, offering a HTML (browser-based) version of an app or service rather than a dedicated iOS app is another way of bypassing Apple’s cut.
Other benefits of Adyen’s payment platform is that merchants and developers can take advantage of a “fully integrated service that removes the burden of security and PCI compliance”, says the company. In addition, app developers can “skin” the mobile payment and checkout process, gaining control of the look and feel, which is said to be an important driver for increased conversion rates.
Merchants already using the new mobile payment platform include Pathe, the largest chain of cinemas in the Europe, via its iPhone app, and Greetz, the online greetings card retailer.

Payment Gateway Query for iphone app

I am developing one application which has use of physical ordering like restaurant food ordering.
Now i am stuck on how will i use the payment Gateway in which i heard from many sites after searching on google that Apple is rejecting the application if I don't want to use the InApp Purchage as it does not support for physical goods.
I don't want to use Paypal and google checkout because it is more expensive as per my client business.
Client uses the website already for their business in which he used the third party payment gateway from www.fatcow.com which use the service of authorize.net
1) I got another option that i can open website mobile pages in Webview and handle it from their but still confuse if apple will reject the app.So please tell me how should i use the 3rd party payment gateway to place my order ?.
2) How can i successful make transaction and credit card processing in application is there any API or something available please provide some information.
Any help will be appreciated .
Thank You.
To my knowledge you should not use any 3rd party payment gateways to process any debit/card transactions until unless its solely meets ISO 8583/8587 protocols and PCI (Payment Card Industries) standards. Any kind of hacky way, will put you in trouble.
nProb,you can use your existing support to make transactions but change you want to made is ask the web team to give you some API's which will carry the transaction process ,
For example , Web Team give a web service - contains all parameters [cost,creditcard etc] ,
then you pass these values from your app with form ui , the the web service will perform transaction & make to return status to your app by json or xml to intimate users that it is a successfull transaction.
Apple will never reject your app , as we have approved 5 similiar payment based apps.
Hope this helps!