Lets create an instance of FlowConfig and add landing page type information
Type of PayPal page to be displayed when a user lands on the PayPal site for checkout. Allowed values: Billing or Login. When set to Billing, the Non-PayPal account landing page is used. When set to Login, the PayPal account login landing page is used.
The URL on the merchant site for transferring to after a bank transfer payment.
When set to "commit", the buyer is shown an amount, and the button text will read "Pay Now" on the checkout page.
Defines the HTTP method to use to redirect the user to a return URL. A valid value is GET
or POST
.
Parameters for style and presentation.
A URL to logo image. Allowed vaues: .gif, .jpg, or .png.
A label that overrides the business name in the PayPal account on the PayPal pages.
Locale of pages displayed by PayPal payment experience.
A label to use as hypertext for the return to merchant link.
A label to use as the title for the note to seller field. Used only when allow_note
is 1
.
Parameters for input fields customization.
Enables the buyer to enter a note to the merchant on the PayPal page during checkout.
Determines whether or not PayPal displays shipping address fields on the experience pages. Allowed values: 0, 1, or 2. When set to 0, PayPal displays the shipping address on the PayPal pages. When set to 1, PayPal does not display shipping address fields whatsoever. When set to 2, if you do not pass the shipping address, PayPal obtains it from the buyer’s account profile. For digital goods, this field is required, and you must set it to 1.
Determines whether or not the PayPal pages should display the shipping address and not the shipping address on file with PayPal for this buyer. Displaying the PayPal street address on file does not allow the buyer to edit that address. Allowed values: 0 or 1. When set to 0, the PayPal pages should not display the shipping address. When set to 1, the PayPal pages should display the shipping address.
Name of the web experience profile. Required. Must be unique
Parameters for flow configuration.
Parameters for style and presentation.
Parameters for input field customization.
Indicates whether the profile persists for three hours or permanently. Set to false
to persist the profile permanently. Set to true
to persist the profile for three hours.
For Sample Purposes Only.
Use this call to create a profile.
NOTE: PLEASE DO NOT USE RESULTPRINTER CLASS IN YOUR ORIGINAL CODE. FOR SAMPLE ONLY
NOTE: PLEASE DO NOT USE RESULTPRINTER CLASS IN YOUR ORIGINAL CODE. FOR SAMPLE ONLY
Create Web Profile
Use the /web-profiles resource to create seamless payment experience profiles. See the payment experience overview for further information about using the /payment resource to create the PayPal payment and pass the experience_profile_id. Documentation available at https://developer.paypal.com/webapps/developer/docs/api/#create-a-web-experience-profile