i'm using CreateInvoice.php this code for creating paypal invoices. But problem is just like express checkout and formal paypal checkout i can't figure out how to add notify_url , cancel_url, return_url while creating invoices.
And in samples i can't find how to accomplish this job.
The parameters you are asking about are not relevant to the invoicing API.
notify_url is to specify an IPN URL. The REST API does not use IPN, though. Instead, it uses Webhooks. You can register those manually within your REST App in your PayPal developer account, or you can set them up with the API.
cancel_url and return_url are used with things like the checkout APIs so that PayPal knows where to send the user when they make those actions. The CreateInvoice invoice API would not need this, though, because there is no redirect to PayPal / login happening with the user.
Instead, it's simply using your API credentials to create the invoice and give you a success or fail result. Based on that result you can redirect wherever you want. Again, you're never leaving your app in this case, so you don't need to specify where to be sent back.
Hope that helps.
Related
Basically I want my users to associate PayPal account in their accounts for identify verification purposes. I am developing a marketplace site and wanted to integrate paypal as my identity verification procedure.
Is there a way to verify email address, first name and last name using PHP like using $_GET variables or $_POST variables? If there is can you show me how?
I tried search and I get Adaptive Accounts GetVerifiedStatus API. But that totally new to me, I don't know where and how to start.
Your best bet here is to make them start, but not complete, an Express Checkout. A normal Express Checkout (referencing Classic but REST works the same way) looks like this
SetExpressCheckout - Tell PayPal you want to authorize $1.00 and have them log in and authorize the payment
GetExpressCheckoutDetails - Take the token from step 1 and get their PayPal account details. Included in this is PAYERSTATUS, which will tell you if their PayPal account is verified or not
DoExpressCheckout - You won't do this, but this is where you finish the process and get funds. Since the data you want is in Step 2, just ignore it and the session will expire.
You could implement GetVerifiedStatus API to determine whether the specified Paypal account's status is verified or unverified.
To use that API, you need to submit the application request to Paypal for approval first. Submission portal link here.
Then use the GetVerifiedStatus API call directly, refer to API request fields,link.
Sample SDK download link.
I want to Use the Paypal API for chained payment (adaptive payment), but i wan't that the user will not get out from my site, so I need to use the DoDirectPayment also...
Is it possible to integrate them both?
I couldn't found the answer for this question...
Thanks.
They both are part of two different API suites from PayPal. The chained payment is from Adaptive Payments API and DoDirectPayment is from PayPal Payments Pro (Direct edition). So make sure you sign up for them as required.
As Prash mentioned, for chained payments w/ PayPal accounts you must redirect to PayPal. But instead of using full browser redirect - you can use the Embedded Payments experience that uses iframe/mini-browser window that provides a more contextual experience to your users.
The user must leave your site in order to login to PayPal, however they are redirected back to your site afterwards where you can process the payment.
I'm looking for a way to build a web application using paypal payments standard. I'd like the user to get redirected to paypal, then fill out their information, and upon completion, add a value in our database saying that they successfully paid. I haven't found a solution or answer to this.
I found this thread for RoR, but didn't find anything for PHP
Paypal Website Payments Standard with a Ruby/Rails application
You can see instructions for a Payment Data Transfer at PayPal's site. Basically, you post the transaction amount and an ID token to their site, the customer pays on paypal.com, and then they're sent back to a pre-defined URL on your site with the transaction details.
I used the NVP API to do that.
i have a client that provide a service on his website.he wants to automate the service orders.
the service has these steps:
1- user submit a form with request.
2- my client review the request, validate it and use the info in this request to :
3- login to another website
4- buy a product from this website using his paypal account.
5- downlad and send the product in email to the user.
i was able to automate all of this using curl.the only problem i have is the purchase process using papal.i didn't deal with paypal before.so i want to know if i can just submit the papal form on the purchase website using curl.or this will not work?
while searching i found something about papal IPN.but i don't know if my client have this IPN in his papal account or not? also, he does not want to give me his papal info. is there is anyway i can do this with fake paypal account to try it?
thank you so much.
First of all, sign up for a PayPal sandbox account: https://developer.paypal.com/devscr?cmd=_signup-run
It's a really slick system PayPal put together for developers to test out stuff.
Secondly, review the PayPal API's at:
https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/library_download_sdks
I believe all you need is the PHP Name-Value pair or Website Payments Standard interfaces.
IPN stands for Instant Payment Notification, it's a way for PayPal to tell you that a payment was made.
What you are looking for is either the PayPal NVP or SOAP interfaces.
I need to setup a payment method on my website that allows a certain user to pay another via two email address'. So essentially, user1 comes to a page, downloads an invoice and has the option to pay that invoice using a link which redirects to paypal with the prefilled details i.e. payeremail, receiveremail, amt, currencycode. Does anyone know which API call I need to make to do this? All I can really see in the API is for other users to pay my account which I already have setup for another function. Thanks in advance.
You need PayPal IPN, after the payment goes through you will receive following information https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_html_IPNandPDTVariables
Here is PHP handler for the IPN, http://www.boolcast.com/development/joomla-custom-paypal-ipn
You can also look at other sample code example on PayPal site.