Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

pay in app
Started by domenico.daraio Dec 09 2013 05:30 AM

12 replies to this topic
payment ios andorid multi-platform
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

domenico.daraio

[GLOBAL: userInfoPane.html]
domenico.daraio
  • Observer

  • 6 posts
  • Corona SDK

Hi All,

my customer ask to me to develop an app (multi platform) where a user can compile a form and, directly in app, can make the payment (via credit card) and, to confirm the successfully a "congratulation" page. 

 

Is possibile to make the payment in the app?

 

which way can i follow?

 

thank you very much 



[TOPIC: post.html]
#2

beckslash

[GLOBAL: userInfoPane.html]
beckslash
  • Contributor

  • 113 posts
  • Corona SDK

You can do that if the payment processor you're using has a rest api.

 

But you won't be able to have the app on iTunes. They don't allow using other payment methods beside their own IAPs.



[TOPIC: post.html]
#3

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

To be able to do that you'll need some extra hardware to interface with a credit card reader. If you're in the US/Canada you could use something like the Square Credit Card Reader, however I don't think they provide a SDK to develop your own apps.

 

I don't know of any hardware solutions that work on both iOS and Android, maybe others can help.

However you'll need Enterprise to be able to interface the card reader SDK with Corona.



[TOPIC: post.html]
#4

Appsicum

[GLOBAL: userInfoPane.html]
Appsicum
  • Observer

  • 25 posts
  • Corona SDK

Yes Apple do not allow which use other api's rather than IAP. So it would not be a useful way to go i guess better to try this without using rest API



[TOPIC: post.html]
#5

dorismartin24

[GLOBAL: userInfoPane.html]
dorismartin24
  • Observer

  • 3 posts
  • Corona SDK

Yes Appsicum is right, you have to try this without using rest API due to Apple only allowed IAP. 



[TOPIC: post.html]
#6

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,527 posts
  • Enterprise

Actually Apple does permit use of other payment options.  If not services like PayPal or Square would not be able to do what they do.  Apple requires you to use IAP if you are doing in-app items, like unlocking features, buying music and media from their store or magazine subscriptions.   But if you're doing real-world physical goods, that works with your good ole Merchant Services.

 

So the answer is it depends on what the person is selling and if it's something that can be done through iTunes then Apple would require IAP.

 

Rob



[TOPIC: post.html]
#7

amirfarazmand

[GLOBAL: userInfoPane.html]
amirfarazmand
  • Contributor

  • 111 posts
  • Corona SDK

Hi Rob,

Are you aware of any app developed by corona that is doing this?
Thanks

[TOPIC: post.html]
#8

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,527 posts
  • Enterprise

Etsy or eBay are a couple of examples.

 

Rob



[TOPIC: post.html]
#9

amirfarazmand

[GLOBAL: userInfoPane.html]
amirfarazmand
  • Contributor

  • 111 posts
  • Corona SDK

Thanks Rob. Actually I tried Paypal and most features work fine although still trying to couple the keys with paypal to make an actual purchase. It is interesting that the camera fill works fine though the Paypal plugin on Android.



[TOPIC: post.html]
#10

amirfarazmand

[GLOBAL: userInfoPane.html]
amirfarazmand
  • Contributor

  • 111 posts
  • Corona SDK

Rob, I came across this sample code on this link https://github.com/GremlinInteractive/plugins_sample_paypal/commits/master.

However, Paypal only gives you an App ID and a secret. Would you know where to get the configuration parameters under the sandbox and user at the end of this code below. Not sure if this app is written for Rest API or Classic API?

 

paypal.config
{
productionClientID = "Paypal Client ID",
sandboxClientID = "same as above I assume",
acceptCreditCards = true, --true/false (optional) -- default false
language = "en", --The users language/locale -- If omitted paypal will show it's views in accordance with the device's current language setting.
merchant =
{
name = "Golf", -- (required) -- The name of the merchant/company
privacyPolicyURL = "http://www.gremlininteractive.com", -- (optional) -- The merchants privacy policy url -- default is paypals privacy policy url
userAgreementURL = "http://www.gremlininteractive.com", -- (optional) -- The user agreement URL -- default is paypals user agreement url
},
rememberUser = false,
environment = "sandbox", -- Valid values: "sandbox", "noNetwork", "production"
-- Uncomment the below lines and fill in with your details, if required.
sandbox = 
{
useDefaults = true,
password = "12345678",
pin = "Your_Sandbox_Pin",
},
user = 
{
email = "?",
phoneNumber = "?",
phoneCountryCode = "?",
},
}


[TOPIC: post.html]
#11

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,527 posts
  • Enterprise

I don't know anything about that plugin.  Though some people were saying that after it was released, PayPal changed the requirements (maybe for iOS only) and they needed a new plugin built with the new SDK.  But since you're using the source, you're probably using the newer SDK.  Hopefully a community member might have gotten further than you have with it, but I suspect you're trailblazing new ground.

 

Rob



[TOPIC: post.html]
#12

amirfarazmand

[GLOBAL: userInfoPane.html]
amirfarazmand
  • Contributor

  • 111 posts
  • Corona SDK

I actually could make a sandbox call by only entering client ID and changing the sandbox table values to profile password and pin="". It is surprising that the secret code provided by paypal wasnt used. When I make a real credit card payment I will add the code for others to use.



[TOPIC: post.html]
#13

carlostg

[GLOBAL: userInfoPane.html]
carlostg
  • Observer

  • 15 posts
  • Corona SDK

Hi amirfarazmand, where you able to make the PayPal plugin work?

 

I need a payment system for "real world goods" in my new app and I'm interested in knowing how did it go.




[topic_controls]
[/topic_controls]