• Сообщество
  • Блог
Документация
Плагины и интеграцииВсе расширения для Medusa от сообществаЭкспертыПодберите специалиста для разработки и развития вашего проекта на Medusa
КейсыПосмотрите примеры Medusa в продакшене и успешные внедрения
Меч Moscow
Комплексная e-commerce платформа на Medusa для московского fashion-бренда

Меч Moscow · Fashion

Нужна помощь в разработке плагина интеграции для Medusa?

Написать намНайти плагины

Gorgo снижает затраты на адаптацию Medusa к локальным рынкам.

Мы разрабатываем плагины интеграции, осуществляем поддержку и развиваем сообщество разработчиков на Medusa в Telegram.

  • Ресурсы Medusa
  • Плагины и интеграции
  • Эксперты
  • Кейсы
  • Medusa Чат в Telegram
  • Medusa Новости в Telegram
  • Документация Gorgo
  • Связаться с нами
  • TelegramGitHub
Плагины
P

Plugin

SumUp payment provider for Medusa v2.

Нужна доработка этого плагина?

Связаться с нами
npm install @sumup/medusa-plugin
Категория
Платежи
Создано
Sumup
Версия
0.1.0
Последнее обновление
5 дней назад
Ежемесячные загрузки
88
Звезды на Github
0
npmNPMGitHubGithub

@sumup/medusa-plugin

SumUp payment provider for Medusa v2.

This plugin lets a Medusa application create and manage SumUp online checkouts from the backend. It supports:

  • Hosted Checkout, where the customer is redirected to SumUp's hosted payment page.
  • Payment Widget, where the storefront mounts SumUp's card widget with the checkout created by Medusa.
  • Refunds through SumUp transactions.
  • Medusa's built-in payment webhook route for asynchronous status updates.

The plugin never handles raw card data directly. SumUp credentials remain on the Medusa backend.

Compatibility

  • Medusa v2.15.x
  • SumUp online checkout flows

Install

yarn add @sumup/medusa-plugin

Configure Medusa

Register the plugin and payment provider in :

1import { defineConfig } from "@medusajs/framework/utils"
2
3export default defineConfig({
4 plugins: [
5 {
6 resolve: "@sumup/medusa-plugin",
7 options: {},
8 },
9 ],
10 modules: [
11 {
12 resolve: "@medusajs/medusa/payment",
13 options: {
14 providers: [
15 {
16 resolve: "@sumup/medusa-plugin/providers/sumup",
17 id: "sumup",
18 options: {
19 apiKey: process.env.SUMUP_API_KEY,
20 merchantCode: process.env.SUMUP_MERCHANT_CODE,
21 checkoutMode: "hosted",
22 returnUrl: `${process.env.MEDUSA_BACKEND_URL}/hooks/payment/sumup_sumup`,
23 redirectUrl: `${process.env.STOREFRONT_URL}/checkout/sumup/return`,
24 },
25 },
26 ],
27 },
28 },
29 ],
30})

After the application starts, enable the provider for the relevant region in Medusa Admin. Per Medusa's payment-provider model, the resulting provider identifier is when the service identifier is and the configured provider is .

Configuration Options

OptionRequiredDescription
YesSumUp API key or access token. Keep it server-side.
YesSumUp merchant code that receives the payment.
NoDefault checkout mode: or . Defaults to .
NoBackend webhook URL. For provider , use .
NoStorefront URL used after redirect or Strong Customer Authentication flows.
NoDefault SumUp checkout description.
NoSumUp SDK request timeout in milliseconds.
NoSumUp SDK retry count.

You can override , , , , and per payment session through provider data.

Hosted Checkout

With , the plugin creates a SumUp checkout with Hosted Checkout enabled. Medusa stores the returned in the payment-session data. The storefront should redirect the customer to that URL.

Use backend state as the source of truth. The storefront should not treat the redirect alone as proof of payment success.

Payment Widget

With , the plugin creates a SumUp checkout without Hosted Checkout enabled. Medusa stores the returned in the payment-session data. The storefront is then responsible for:

  • Loading SumUp's widget SDK.
  • Mounting the widget with the checkout ID.
  • Asking the backend to re-check the payment state after widget success.

Minimal storefront snippets are available in examples/nextjs/README.md.

Webhooks

Medusa provides a built-in webhook listener route for payment providers at:

/hooks/payment/[identifier]_[provider]

For this plugin, with service identifier and provider , the webhook URL is:

https://your-medusa-backend.com/hooks/payment/sumup_sumup

The plugin's implementation follows Medusa's payment-webhook flow: it receives the webhook payload, retrieves the checkout from SumUp, maps the result to a Medusa payment action, and returns the payment session reference back to Medusa.

What the Plugin Stores

The payment-session data returned by the provider includes:

  • for hosted flows
  • and when available
  • and

Current Behavior and Limitations

  • checks the remote SumUp checkout status rather than performing a separate authorization step.
  • does not trigger a separate capture API call. It only succeeds once the SumUp checkout is already paid.
  • If the amount or currency changes before payment, deactivates the old checkout and creates a replacement checkout.
  • Refunds require a successful SumUp transaction.
  • The plugin is built for SumUp online payments, not terminal or card-present flows.

Sandbox Checklist

  • Verify one successful Hosted Checkout payment.
  • Verify one successful Payment Widget payment.
  • Verify at least one webhook-driven payment update.
  • Verify one full refund and one partial refund.
  • Test SumUp's deliberate failure path with amount .
  • Verify expired or canceled checkouts map cleanly back into Medusa session state.

Examples

  • Consumer storefront snippets: examples/nextjs/README.md
  • Local end-to-end playground: examples/docker/README.md

Contributing

Maintainer and release workflow documentation lives in CONTRIBUTING.md.

Еще в этой категории

Посмотреть все
Платежи
Braintree logo

Braintree

От Lambda Curry

Поддержка платежей и 3D Secure через Braintree

Загрузка данных
GitHubnpm
Платежи
Pay. logo

Pay.

От Webbers

Принимайте кредитные карты, цифровые платежи и купи сейчас — плати потом

Загрузка данных
GitHubnpm
Платежи
Mollie logo

Mollie

От Variable Vic

Легко принимайте мультивалютные платежи через Mollie

Загрузка данных
GitHubnpm