1
0
Files
PayPal-PHP-Server-SDK/doc/models/paypal-wallet-experience-context.md
Patrick Powers 504c367386 Release 0.7.0
Beta Release 0.7.0 including:

- Bug fixes
- Updated model/function names
- Updated models to reflect changes in APIs
2025-03-20 13:18:55 -05:00

4.0 KiB

Paypal Wallet Experience Context

Customizes the payer experience during the approval process for payment with PayPal. Note: Partners and Marketplaces might configure brand_name and shipping_preference during partner account setup, which overrides the request values.

Structure

PaypalWalletExperienceContext

Fields

Name Type Tags Description Getter Setter
brandName ?string Optional The label that overrides the business name in the PayPal account on the PayPal site. The pattern is defined by an external party and supports Unicode.
Constraints: Minimum Length: 1, Maximum Length: 127, Pattern: ^.*$
getBrandName(): ?string setBrandName(?string brandName): void
locale ?string Optional The language tag for the language in which to localize the error-related strings, such as messages, issues, and suggested actions. The tag is made up of the ISO 639-2 language code, the optional ISO-15924 script tag, and the ISO-3166 alpha-2 country code or M49 region code.
Constraints: Minimum Length: 2, Maximum Length: 10, Pattern: ^[a-z]{2}(?:-[A-Z][a-z]{3})?(?:-(?:[A-Z]{2}|[0-9]{3}))?$
getLocale(): ?string setLocale(?string locale): void
shippingPreference ?string(PaypalWalletContextShippingPreference) Optional The location from which the shipping address is derived.
Default: PaypalWalletContextShippingPreference::GET_FROM_FILE
Constraints: Minimum Length: 1, Maximum Length: 24, Pattern: ^[A-Z_]+$
getShippingPreference(): ?string setShippingPreference(?string shippingPreference): void
returnUrl ?string Optional Describes the URL. getReturnUrl(): ?string setReturnUrl(?string returnUrl): void
cancelUrl ?string Optional Describes the URL. getCancelUrl(): ?string setCancelUrl(?string cancelUrl): void
landingPage ?string(PaypalExperienceLandingPage) Optional The type of landing page to show on the PayPal site for customer checkout.
Default: PaypalExperienceLandingPage::NO_PREFERENCE
Constraints: Minimum Length: 1, Maximum Length: 13, Pattern: ^[0-9A-Z_]+$
getLandingPage(): ?string setLandingPage(?string landingPage): void
userAction ?string(PaypalExperienceUserAction) Optional Configures a Continue or Pay Now checkout flow.
Default: PaypalExperienceUserAction::CONTINUE_
Constraints: Minimum Length: 1, Maximum Length: 8, Pattern: ^[0-9A-Z_]+$
getUserAction(): ?string setUserAction(?string userAction): void
paymentMethodPreference ?string(PayeePaymentMethodPreference) Optional The merchant-preferred payment methods.
Default: PayeePaymentMethodPreference::UNRESTRICTED
Constraints: Minimum Length: 1, Maximum Length: 255, Pattern: ^[0-9A-Z_]+$
getPaymentMethodPreference(): ?string setPaymentMethodPreference(?string paymentMethodPreference): void
orderUpdateCallbackConfig ?CallbackConfiguration Optional CallBack Configuration that the merchant can provide to PayPal/Venmo. getOrderUpdateCallbackConfig(): ?CallbackConfiguration setOrderUpdateCallbackConfig(?CallbackConfiguration orderUpdateCallbackConfig): void

Example (as JSON)

{
  "shipping_preference": "GET_FROM_FILE",
  "landing_page": "NO_PREFERENCE",
  "user_action": "CONTINUE",
  "payment_method_preference": "UNRESTRICTED",
  "brand_name": "brand_name6",
  "locale": "locale0",
  "return_url": "return_url8",
  "cancel_url": "cancel_url0"
}