Skip to content

add dummy payment app to monorepo#2335

Draft
lkostrowski wants to merge 1 commit intomainfrom
dummy-payment-app
Draft

add dummy payment app to monorepo#2335
lkostrowski wants to merge 1 commit intomainfrom
dummy-payment-app

Conversation

@lkostrowski
Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings April 22, 2026 07:50
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 22, 2026

⚠️ No Changeset found

Latest commit: f99847f

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

9 Skipped Deployments
Project Deployment Actions Updated (UTC)
saleor-app-avatax Skipped Skipped Apr 22, 2026 7:50am
saleor-app-cms Skipped Skipped Apr 22, 2026 7:50am
saleor-app-klaviyo Skipped Skipped Apr 22, 2026 7:50am
saleor-app-payment-np-atobarai Skipped Skipped Apr 22, 2026 7:50am
saleor-app-payment-stripe Skipped Skipped Apr 22, 2026 7:50am
saleor-app-products-feed Skipped Skipped Apr 22, 2026 7:50am
saleor-app-search Skipped Skipped Apr 22, 2026 7:50am
saleor-app-segment Skipped Skipped Apr 22, 2026 7:50am
saleor-app-smtp Skipped Skipped Apr 22, 2026 7:50am

Request Review

},

ignoreOutgoingUrls: [
(url) => url.includes("ingest.sentry.io"),
onClick={() => {
setNotFoundError(false);
if (transactionId) {
router.push(`/app/transactions/${transactionId}`);
@github-actions
Copy link
Copy Markdown
Contributor

Differences Found

✅ No packages or licenses were added.

Summary

Expand
License Name Package Count Packages
0BSD 1
Packages
  • tslib
CC BY-SA 4.0 1
Packages
  • @cspell/dict-en-common-misspellings
CC0-1.0 1
Packages
  • type-fest
MIT (http://mootools.net/license.txt) 1
Packages
  • slick
MIT/X11 1
Packages
  • nub
Public Domain 1
Packages
  • jsonify
Python-2.0 1
Packages
  • argparse
SEE LICENSE IN LICENSE 1
Packages
  • spawndamnit
SEE LICENSE IN LICENSE.md 1
Packages
  • lightcookie
Unlicense 1
Packages
  • @sinonjs/text-encoding
WTFPL 1
Packages
  • opener
BlueOak-1.0.0 3
Packages
  • jackspeak
  • package-json-from-dist
  • path-scurry
CC-BY-4.0 3
Packages
  • @saleor/macaw-ui
  • caniuse-lite
  • saleor-apps
LGPL-3.0-or-later 11
Packages
  • @img/sharp-libvips-darwin-arm64
  • @img/sharp-libvips-darwin-x64
  • @img/sharp-libvips-linux-arm
  • @img/sharp-libvips-linux-arm64
  • @img/sharp-libvips-linux-s390x
  • @img/sharp-libvips-linux-x64
  • @img/sharp-libvips-linuxmusl-arm64
  • @img/sharp-libvips-linuxmusl-x64
  • @img/sharp-wasm32
  • @img/sharp-win32-ia32
  • @img/sharp-win32-x64
BSD-2-Clause 22
Packages
  • cheerio-select
  • css-select
  • css-what
  • domelementtype
  • domhandler
  • domutils
  • dotenv
  • entities
  • escodegen
  • eslint-scope
  • espree
  • esprima
  • esrecurse
  • estraverse
  • esutils
  • glob-to-regexp
  • nth-check
  • shimmer
  • terser
  • uglify-js
  • And 2 more...
<<missing>> 27
Packages
  • @saleor/app-problems
  • @saleor/apps-domain
  • @saleor/apps-logger
  • @saleor/apps-otel
  • @saleor/apps-shared
  • @saleor/apps-trpc
  • @saleor/apps-ui
  • @saleor/dynamo-config-repository
  • @saleor/errors
  • @saleor/eslint-config-apps
  • @saleor/handlebars
  • @saleor/react-hook-form-macaw
  • @saleor/sentry-utils
  • @saleor/typescript-config-apps
  • @saleor/webhook-utils
  • busboy
  • json-query
  • saleor-app-avatax
  • saleor-app-cms
  • saleor-app-klaviyo
  • And 7 more...
BSD-3-Clause 48
Packages
  • @protobufjs/aspromise
  • @protobufjs/base64
  • @protobufjs/codegen
  • @protobufjs/eventemitter
  • @protobufjs/fetch
  • @protobufjs/float
  • @protobufjs/inquire
  • @protobufjs/path
  • @protobufjs/pool
  • @protobufjs/utf8
  • @saleor/app-sdk
  • @saleor/eslint-plugin-saleor-app
  • @sentry/cli
  • @sentry/cli-darwin
  • @sentry/cli-linux-arm
  • @sentry/cli-linux-arm64
  • @sentry/cli-linux-i686
  • @sentry/cli-linux-x64
  • @sentry/cli-win32-i686
  • @sentry/cli-win32-x64
  • And 28 more...
ISC 55
Packages
  • @bundled-es-modules/cookie
  • @bundled-es-modules/statuses
  • @bundled-es-modules/tough-cookie
  • @isaacs/cliui
  • abbrev
  • anymatch
  • boolbase
  • cli-width
  • cliui
  • concat-with-sourcemaps
  • electron-to-chromium
  • fastq
  • flatted
  • foreground-child
  • form-data-lite
  • fs.realpath
  • get-caller-file
  • glob
  • glob-parent
  • graceful-fs
  • And 35 more...
Apache-2.0 239
Packages
  • @ampproject/remapping
  • @aws-crypto/crc32
  • @aws-crypto/crc32c
  • @aws-crypto/ie11-detection
  • @aws-crypto/sha1-browser
  • @aws-crypto/sha256-browser
  • @aws-crypto/sha256-js
  • @aws-crypto/supports-web-crypto
  • @aws-crypto/util
  • @aws-sdk/abort-controller
  • @aws-sdk/chunked-blob-reader
  • @aws-sdk/client-dynamodb
  • @aws-sdk/client-s3
  • @aws-sdk/client-sso
  • @aws-sdk/client-sso-oidc
  • @aws-sdk/client-sts
  • @aws-sdk/config-resolver
  • @aws-sdk/core
  • @aws-sdk/credential-provider-env
  • @aws-sdk/credential-provider-http
  • And 219 more...
MIT 1410
Packages
  • @0no-co/graphql.web
  • @adobe/css-tools
  • @algolia/cache-browser-local-storage
  • @algolia/cache-common
  • @algolia/cache-in-memory
  • @algolia/client-account
  • @algolia/client-analytics
  • @algolia/client-common
  • @algolia/client-personalization
  • @algolia/client-search
  • @algolia/logger-common
  • @algolia/logger-console
  • @algolia/recommend
  • @algolia/requester-browser-xhr
  • @algolia/requester-common
  • @algolia/requester-node-http
  • @algolia/transporter
  • @apidevtools/json-schema-ref-parser
  • @ardatan/relay-compiler
  • @ardatan/sync-fetch
  • And 1390 more...

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new “dummy-payment” Next.js app under apps/ intended to act as a dummy payment gateway for exercising Saleor Transactions API flows in this monorepo.

Changes:

  • Introduces a full Next.js Pages Router app with Saleor App SDK integration (manifest/register endpoints + sync webhooks).
  • Adds tRPC + urql GraphQL client plumbing plus UI pages for checkout/transactions tooling.
  • Adds observability/logging scaffolding (OpenTelemetry + Sentry) and local tooling (codegen, vitest, docker devfile).

Reviewed changes

Copilot reviewed 115 out of 128 changed files in this pull request and generated 23 comments.

Show a summary per file
File Description
apps/dummy-payment/vitest.config.ts Adds Vitest config for the new app
apps/dummy-payment/tsconfig.json Adds TypeScript config for the new app
apps/dummy-payment/src/trpc-client.ts Adds tRPC Next client configuration
apps/dummy-payment/src/styles/globals.css Adds global CSS for the app
apps/dummy-payment/src/setup-tests.ts Adds Vitest setup placeholder
apps/dummy-payment/src/server/server.ts Adds base tRPC server helpers
apps/dummy-payment/src/server/routers/transaction-reporter.router.ts Adds tRPC router for reporting transaction events
apps/dummy-payment/src/server/routers/app-router.ts Composes tRPC app router
apps/dummy-payment/src/server/procedure/procedure-with-graphql-client.ts Adds tRPC middleware to attach a GraphQL client
apps/dummy-payment/src/server/middleware/attach-app-token.ts Adds middleware to fetch APL token for Saleor
apps/dummy-payment/src/saleor-app.ts Configures SaleorApp + selectable APL backends
apps/dummy-payment/src/providers/GraphQLProvider.tsx Adds urql Provider based on AppBridge state
apps/dummy-payment/src/pages/index.tsx Adds public landing page + install helper
apps/dummy-payment/src/pages/app/transactions/index.tsx Adds transaction lookup page (PSP/id)
apps/dummy-payment/src/pages/app/transactions/[id].tsx Adds transaction details + event reporting UI
apps/dummy-payment/src/pages/app/index.tsx Adds app “home” page
apps/dummy-payment/src/pages/app/configuration.tsx Adds placeholder configuration page
apps/dummy-payment/src/pages/app/checkout.tsx Adds UI for creating checkout + initializing transaction
apps/dummy-payment/src/pages/api/webhooks/transaction-refund-requested.ts Adds TRANSACTION_REFUND_REQUESTED sync webhook
apps/dummy-payment/src/pages/api/webhooks/transaction-process-session.ts Adds TRANSACTION_PROCESS_SESSION sync webhook
apps/dummy-payment/src/pages/api/webhooks/transaction-initialize-session.ts Adds TRANSACTION_INITIALIZE_SESSION sync webhook
apps/dummy-payment/src/pages/api/webhooks/transaction-charge-requested.ts Adds TRANSACTION_CHARGE_REQUESTED sync webhook
apps/dummy-payment/src/pages/api/webhooks/transaction-cancel-requested.ts Adds TRANSACTION_CANCELATION_REQUESTED sync webhook
apps/dummy-payment/src/pages/api/webhooks/payment-gateway-initialize-session.ts Adds PAYMENT_GATEWAY_INITIALIZE_SESSION sync webhook
apps/dummy-payment/src/pages/api/trpc/[trpc].ts Adds tRPC Next API handler and context
apps/dummy-payment/src/pages/api/register.ts Adds Saleor app registration endpoint
apps/dummy-payment/src/pages/api/manifest.ts Adds Saleor manifest endpoint wiring webhooks
apps/dummy-payment/src/pages/_app.tsx Adds Next.js app shell with AppBridge + providers
apps/dummy-payment/src/order-example.tsx Adds example component querying orders
apps/dummy-payment/src/modules/validation/sync-transaction.ts Adds Zod schema for controlling webhook behavior
apps/dummy-payment/src/modules/validation/refund-webhook.ts Adds Zod schema/response types for refund webhook
apps/dummy-payment/src/modules/validation/common.ts Adds shared Zod enums/schemas
apps/dummy-payment/src/modules/validation/charge-webhook.ts Adds Zod schema/response types for charge webhook
apps/dummy-payment/src/modules/validation/cancel-webhook.ts Adds Zod schema/response types for cancel webhook
apps/dummy-payment/src/modules/url/app-url-generator.ts Adds helper to build dashboard URLs back to the app
apps/dummy-payment/src/modules/transaction/transaction-refund-checker.ts Adds helper for refund amount checking
apps/dummy-payment/src/modules/transaction/transaction-psp-finder.ts Adds helper to find PSP reference from events
apps/dummy-payment/src/modules/configuration/app-config.ts Adds (placeholder) app configuration schema
apps/dummy-payment/src/logger-context.ts Adds server-side logger context singleton
apps/dummy-payment/src/lib/zod-error.ts Adds helper to flatten Zod errors to a message string
apps/dummy-payment/src/lib/transaction-actions.ts Adds mapping from event type to available actions
apps/dummy-payment/src/lib/theme-synchronizer.tsx Syncs Macaw theme to Dashboard theme
apps/dummy-payment/src/lib/otel/shared-config.ts Adds shared OTEL config
apps/dummy-payment/src/lib/otel/otel-wrapper.ts Adds wrapper to create spans and flush OTEL
apps/dummy-payment/src/lib/otel/otel-traces-setup.ts Adds OTEL trace exporter/processor setup
apps/dummy-payment/src/lib/otel/otel-tracer.ts Adds tracer getter
apps/dummy-payment/src/lib/otel/otel-logs-setup.ts Adds OTEL logs exporter/processor setup
apps/dummy-payment/src/lib/otel/otel-graphql-utils.ts Adds span attribute helpers for GraphQL
apps/dummy-payment/src/lib/otel/otel-exchange.ts Adds urql exchange emitting OTEL spans
apps/dummy-payment/src/lib/otel/lib/race.ts Adds timeout helper used for flushes
apps/dummy-payment/src/lib/otel/lib/observability-attributes.ts Adds OTEL attribute names/constants
apps/dummy-payment/src/lib/otel/instrumentation.ts Adds NodeSDK OTEL instrumentation setup
apps/dummy-payment/src/lib/otel/get-attributes-from-request.ts Adds request->span attribute extraction
apps/dummy-payment/src/lib/no-ssr-wrapper.tsx Adds SPA-only wrapper for iframe usage
apps/dummy-payment/src/lib/logger/logger.ts Adds tslog base logger + formatter
apps/dummy-payment/src/lib/logger/logger-vercel-transport.ts Adds Vercel runtime log drain transport
apps/dummy-payment/src/lib/logger/logger-sentry-transport.ts Adds Sentry breadcrumb transport
apps/dummy-payment/src/lib/logger/logger-context.ts Adds AsyncLocalStorage-based logger context
apps/dummy-payment/src/lib/logger/logger-console-transport.ts Adds local console transport
apps/dummy-payment/src/lib/logger/create-logger.ts Wires transports + exports logger factory
apps/dummy-payment/src/lib/is-in-iframe.ts Adds iframe detection helper
apps/dummy-payment/src/lib/invariant.ts Adds invariant helper + error type
apps/dummy-payment/src/lib/create-graphql-client.ts Adds urql client factory with auth exchange
apps/dummy-payment/src/errors.ts Adds base error types for the app
apps/dummy-payment/src/db/dynamo-main-table.ts Adds DynamoDB table wrapper for APL
apps/dummy-payment/src/db/dynamo-client.ts Adds DynamoDB client creation helper
apps/dummy-payment/src/components/StatusChip.tsx Adds status chip component for event types
apps/dummy-payment/src/components/NavigationTile.tsx Adds navigation tile component
apps/dummy-payment/src/components/Navigation.tsx Adds app navigation bar and routes
apps/dummy-payment/src/components/AppContent.tsx Adds wrapper for app content layout
apps/dummy-payment/sentry.server.config.ts Adds Sentry server config
apps/dummy-payment/sentry.edge.config.ts Adds Sentry edge config
apps/dummy-payment/sentry.client.config.ts Adds Sentry client config
apps/dummy-payment/scripts/generate-app-webhooks-types.ts Adds script to generate TS types from Saleor JSON schemas
apps/dummy-payment/public/logo.png Adds app logo asset
apps/dummy-payment/package.json Adds app package definition and dependencies
apps/dummy-payment/next.config.js Adds Next.js config (Sentry + analyzer + OTEL warning ignore)
apps/dummy-payment/next-env.d.ts Adds Next.js TS env types
apps/dummy-payment/graphql/subscriptions/TransactionRefundRequested.graphql Adds subscription document for codegen
apps/dummy-payment/graphql/subscriptions/TransactionProcessSession.graphql Adds subscription document for codegen
apps/dummy-payment/graphql/subscriptions/TransactionInitializeSession.graphql Adds subscription document for codegen
apps/dummy-payment/graphql/subscriptions/TransactionChargeRequested.graphql Adds subscription document for codegen
apps/dummy-payment/graphql/subscriptions/TransactionCancelRequested.graphql Adds subscription document for codegen
apps/dummy-payment/graphql/subscriptions/PaymentGatewayInitializeSession.graphql Adds subscription document for codegen
apps/dummy-payment/graphql/subscriptions/.gitkeep Keeps subscriptions dir tracked
apps/dummy-payment/graphql/queries/TransactionDetailsViaPsp.graphql Adds query for transaction lookup by PSP
apps/dummy-payment/graphql/queries/TransactionDetailsViaId.graphql Adds query for transaction lookup by id
apps/dummy-payment/graphql/queries/ProductList.graphql Adds query for products list
apps/dummy-payment/graphql/queries/FetchAppDetails.graphql Adds query for app metadata
apps/dummy-payment/graphql/queries/ChannelsList.graphql Adds query for channels
apps/dummy-payment/graphql/queries/.gitkeep Keeps queries dir tracked
apps/dummy-payment/graphql/mutations/UpdateDelivery.graphql Adds mutation to set delivery method
apps/dummy-payment/graphql/mutations/TransactionEventReport.graphql Adds mutation to report transaction events
apps/dummy-payment/graphql/mutations/InitializeTransaction.graphql Adds mutation to initialize a transaction
apps/dummy-payment/graphql/mutations/CreateCheckout.graphql Adds mutation to create checkout
apps/dummy-payment/graphql/mutations/CompleteCheckout.graphql Adds mutation to complete checkout
apps/dummy-payment/graphql/mutations/.gitkeep Keeps mutations dir tracked
apps/dummy-payment/graphql/fragments/TransactionRefundRequestedEvent.graphql Adds webhook fragment
apps/dummy-payment/graphql/fragments/TransactionProcessSessionEvent.graphql Adds webhook fragment
apps/dummy-payment/graphql/fragments/TransactionInitializeSessionEvent.graphql Adds webhook fragment
apps/dummy-payment/graphql/fragments/TransactionChargeRequestedEvent.graphql Adds webhook fragment
apps/dummy-payment/graphql/fragments/TransactionCancelRequestedEvent.graphql Adds webhook fragment
apps/dummy-payment/graphql/fragments/Transaction.graphql Adds transaction fragment
apps/dummy-payment/graphql/fragments/SyncWebhookTransaction.graphql Adds sync webhook transaction fragment
apps/dummy-payment/graphql/fragments/PaymentGatewayRecipient.graphql Adds recipient fragment
apps/dummy-payment/graphql/fragments/PaymentGatewayInitializeSessionEvent.graphql Adds webhook fragment
apps/dummy-payment/graphql/fragments/Money.graphql Adds money fragment
apps/dummy-payment/graphql/fragments/BasicWebhookMetadata.graphql Adds basic webhook metadata fragment
apps/dummy-payment/graphql/fragments/.gitkeep Keeps fragments dir tracked
apps/dummy-payment/generated/app-webhooks-types/transaction-refund-requested.ts Adds generated webhook response types
apps/dummy-payment/generated/app-webhooks-types/transaction-process-session.ts Adds generated webhook response types
apps/dummy-payment/generated/app-webhooks-types/transaction-initialize-session.ts Adds generated webhook response types
apps/dummy-payment/generated/app-webhooks-types/payment-gateway-initialize-session.ts Adds generated webhook response types
apps/dummy-payment/generated/app-webhooks-types/.gitkeep Keeps generated types dir tracked
apps/dummy-payment/LICENSE Adds license file for the app
apps/dummy-payment/Dockerfile.dev Adds dev Dockerfile
apps/dummy-payment/CLAUDE.md Adds agent guidance doc
apps/dummy-payment/AGENTS.md Adds agent guidance doc
apps/dummy-payment/.prettierrc Adds app-local prettier config
apps/dummy-payment/.prettierignore Adds app-local prettier ignore
apps/dummy-payment/.npmrc Adds app-local npmrc
apps/dummy-payment/.graphqlrc.yml Adds GraphQL codegen config
apps/dummy-payment/.gitignore Adds app-local gitignore
apps/dummy-payment/.gitallowed Adds gitallowed list
apps/dummy-payment/.eslintrc Adds app-local eslint config
apps/dummy-payment/.env.example Adds env example file

Comment on lines +19 to +23
useEffect(() => {
if (data) {
const transaction = data?.orders?.edges[0]?.node?.transactions.find((transaction) => {
return transaction?.pspReference === pspReference;
});
Comment on lines +1 to +3
import { MiddlewareFunction, TRPCError } from "@trpc/server";
import { middleware, procedure } from "../server";
import { attachAppToken } from "../middleware/attach-app-token";
Comment on lines +48 to +52
const [otherError, setOtherError] = React.useState<string | null>(null);

const transactionId = router.query.id as string;

const [eventType, setEventType] = React.useState<EventReporterOptions>({
Comment on lines +18 to +22
return next({
ctx: {
apiClient: client,
},
});
Comment on lines +3 to +7
export const appConfigSchema = z.object({
refundConfig: z.enum(["SYNC_SUCESS", "ASYNC_SUCCESS", "ASYNC_FAILURE", "SYNC_FAILURE"]),
chargeConfig: z.enum(["SYNC_SUCESS", "ASYNC_SUCCESS", "ASYNC_FAILURE", "SYNC_FAILURE"]),
cancelConfig: z.enum(["SYNC_SUCESS", "ASYNC_SUCCESS", "ASYNC_FAILURE", "SYNC_FAILURE"]),
// TODO: Add implementation for ASYNC events via event queue
Comment on lines +182 to +184
<Box display="flex" alignItems="center" gap={2}>
<Text>Selet event type:</Text>
<Combobox
Comment on lines +91 to +95
try {
// return await loggerContext.wrap(() => wrappingTarget.apply(thisArg, [req, res]));

wrappingTarget.apply(thisArg, [req, res]);
} catch (error) {
@@ -0,0 +1,14 @@
FROM node:20.12-alpine
Comment on lines +25 to +29
return next({
ctx: {
authData,
// TODO: Remove appToken
appToken: authData.token,
Comment on lines +30 to +32
},
ssr: true,
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants