Search for a command to run...
In this document, you’ll learn how to install and configure the T-Kassa payment provider for Medusa.
yarn add @gorgo/medusa-payment-tkassa# ornpm install @gorgo/medusa-payment-tkassa
Add the provider configuration in your file of the Medusa admin application:
# ...module.exports = defineConfig({# ...modules: [{resolve: "@medusajs/medusa/payment",options: {providers: [{resolve: "@gorgo/medusa-payment-tkassa/providers/payment-tkassa",id: "tkassa",options: {terminalKey: process.env.TKASSA_TERMINAL_KEY,password: process.env.TKASSA_PASSWORD,capture: true,useReceipt: true,ffdVersion: "1.05",taxation: "osn",taxItemDefault: "none",taxShippingDefault: "none"},}]}}]})
Add environment variables with your shop identifier and secret from your T-Business account:
TKASSA_TERMINAL_KEY=123456789TKASSA_PASSWORD=supersecret
| Option | Description | Required | Default |
|---|---|---|---|
| Terminal key provided by T-Kassa (required for authentication) | Yes | - | |
| Password for request signing (required for authentication) | Yes | - | |
| Automatic payment capture: - for one-step payment, passes to T-Kassa API - for two-steps payment, passes payment | No | ||
| Enable receipt generation according to Russian fiscal data format (FFD) | No | ||
| Fiscal data format version: or Applicable only if = | No | - | |
| Tax system type: - : General - : Simplified (income) - : Simplified (income-expenses) - : Agricultural - : Patent Applicable only if = | No | - | |
| Default VAT rate for products: - : No VAT - : 0% - : 5% - : 7% - : 10% - : 20% - : 5/105 - : 7/107 - : 10/110 - : 20/120 Applicable only if = | No | - | |
| Default VAT rate for shipping, same options as Applicable only if = | No | - |
To properly handle payment notifications from T-Kassa, configure webhooks in your T-Business account as following:
Navigate to → → Choose your shop → → Choose or Terminal → Click to open the setting window
Choose to send Notifications
Add a URL like:
Change with your medusa store domain.
Warning! T-Kassa expects an response message to confirm successful webhook processing and to prevent duplicate notifications. Currently, Medusa does not natively support custom webhook response messages, but webhooks are still processed correctly without this. For more details, check out the related discussion.