Skip to content

Trasversale · Package · Active

@platform/contracts-payments

Shared payment contract package for provider descriptors, pricing items, checkout sessions, purchase and subscription records, tenant plan status, and normalized payment event delivery.

  • TypeScript declarations
  • Dual package exports

Spec sheet

Package name

@platform/contracts-payments

Repository path

platform-shared-packages/packages/contracts-payments

Primary consumer

platform-payments-service, FunnelAI backend and CS Transaction API

Responsibilities

  • Define shared DTOs for payment provider discovery and pricing catalog operations.
  • Keep checkout session request and response shapes aligned between Core Payments and product BFFs.
  • Define purchase, subscription, tenant plan status and consumer event payload types.

Interfaces and contract surface

  • PaymentProvidersResponse
  • PaymentPricingItem
  • CreatePaymentCheckoutSessionPayload
  • CreatePaymentCheckoutSessionResponse
  • PaymentTenantPlanStatusResponse
  • PaymentConsumerEventPayload
  • PaymentEventDelivery

Consumers

Notes

  • Use this package instead of redefining billing and payment shapes inside product repositories.

Source references

  • platform-shared-packages/packages/contracts-payments/package.json
  • platform-shared-packages/packages/contracts-payments/index.d.ts
  • platform-payments-service/README.md

Quando usarlo

Usa @platform/contracts-payments quando un backend prodotto integra platform-payments-service per catalogo pricing, checkout, stato piano, purchase/subscription o eventi payment normalizzati.

Il package contiene solo contratti TypeScript: la logica provider, la validazione webhook e la persistenza restano nel servizio CORE Payments.

Workspace reference: /Users/jeanpaul/projects/cs-repository