Hyperse
  • Pricing
  • FAQs
Newsletter

Subscribe to our newsletter

Receive weekly updates with latest collections and exclusive offers, straight to your inbox.

Hyperse

Headless commerce solutions for brands, developers, and modern ecommerce teams.

Explore

  • Home
  • About Us
  • Partners
  • FAQs

Legal & resources

  • Proposal
  • Privacy Policy
  • Terms & Conditions

© 2026 Hyperse. All rights reserved.


  1. Home
  2. Vendure Plugins
  3. hps-plugin-payment-paypal
hps-plugin-payment-paypal

hps-plugin-payment-paypal

By Hyperse

hps-plugin-payment-paypal is a Payment Paypal plugin in the Hub Pay group.hps-plugin-payment-paypal provides Payment Paypal plugin capabilities for Hub Pay. Payments, billing, invoicing, and money-related capabilities. It is especially useful for payment workflows.

CoreVendure Plugins

Specifications

Technical details and package information for this product.

Package

@hyperse-hub/hps-plugin-payment-paypal

Support by

Hyperse

Support languages

TypeScript, JavaScript, Prolog, Shell, CSS

Integration type

Core

Category

Vendure Plugins

Compatible with

^3.0.0

Latest version

1.0.12

Downloads

0

Repository

ssh://git@github.com/hyperse-hub/hub-pay

Last published

July 13, 2026

Description
Changelog
loading...

On this page

  • @hyperse-hub/hps-plugin-payment-paypal
    • 1. Overview
    • 2. Requirements
    • 3. Install
    • 4. Vendure registration
    • 5. Key concepts
      • 5.1 Payment method configuration (Admin)
      • 5.2 HTTP endpoint
      • 5.3 Shop GraphQL
      • 5.4 End-to-end flow (mental model)
    • 6. Options
    • 7. Related packages
    • 8. License

@hyperse-hub/hps-plugin-payment-paypal

PayPal payment integration for Vendure: payment method handler, REST webhook, and Shop API mutations that work with @hyperse-hub/hps-plugin-payment-core shared flows.

1. Overview

  1. Vendure payment handler — Registers handler code paypal-payment-provider with Admin-configurable args (sandbox, brand, OAuth credentials, optional publishable key).
  2. Webhook-driven settlement — PayPal notifies your server; the controller verifies the event and completes the order payment path in line with Vendure’s order state machine.
  3. Storefront — Creates a PayPal-side payment intent via GraphQL, then uses Vendure’s standard addPaymentToOrder and optionally refreshPaymentStatus from the core plugin for polling.

2. Requirements

  • Vendure >= 3.0.0
  • Node.js >= 20
  • @hyperse-hub/hps-plugin-payment-core (installed transitively when you add this package)

3. Install

yarn add @hyperse-hub/hps-plugin-payment-paypal

4. Vendure registration

import { HpsPluginPaymentPaypal } from '@hyperse-hub/hps-plugin-payment-paypal'

HpsPluginPaymentCore is imported by this plugin; you do not need to register the core plugin separately unless you rely on it for other custom code.

5. Key concepts

5.1 Payment method configuration (Admin)

Create a PaymentMethod in the Admin UI using the PayPal handler. Configure:

  • Sandbox — Use PayPal sandbox for non-production.
  • Client credentials — Client ID and secret from the PayPal developer dashboard.
  • Brand name — Shown in PayPal checkout where applicable.
  • Publishable key (optional) — Exposed to the storefront for client-side SDK usage; see Shop API below.

Store any extra JSON the storefront needs in PaymentMethod.customFields.clientConfig (core plugin); the core resolves PaymentMethodQuote.clientConfig for GraphQL quotes.

5.2 HTTP endpoint

  • Webhook / payment notification — POST /payment/paypal
    Configure the same URL in the PayPal developer app so capture and completion events reach Vendure. Signature headers are validated by the controller.

5.3 Shop GraphQL

  • createPaypalPaymentIntent — Mutation (authenticated customer, active order). Returns a PayPal transaction identifier used to drive the JS SDK or redirect flow.
  • PaymentMethodQuote.paypalPublishableKey — Resolves the optional publishable key from the payment method handler args for the quoted method.
  • refreshPaymentStatus — Provided by payment-core; use after redirect or when the client needs to sync settlement with the server.

5.4 End-to-end flow (mental model)

  1. Customer has an active order; storefront calls createPaypalPaymentIntent.
  2. Customer completes payment in PayPal (hosted fields, redirect, or SDK).
  3. Storefront calls addPaymentToOrder with metadata your handler expects (see handler implementation).
  4. PayPal sends a webhook to /payment/paypal; the server verifies and settles the payment.
  5. If the UI needs a safety net, poll refreshPaymentStatus with orderId + transactionId returned from addPaymentToOrder.

6. Options

HpsPluginPaymentPaypal.init({}) accepts an options object; extend HpsPluginPaymentPaypalOptions in this package when new settings are added. Currently the surface is minimal—most configuration lives on the PaymentMethod handler args in Admin.

7. Related packages

  • @hyperse-hub/hps-plugin-payment-core — Shared refreshPaymentStatus, PaymentMethodQuote.clientConfig, and PaymentHelperService.

8. License

MIT

;
// plugins: [
// HpsPluginPaymentPaypal.init({}),
// ],