Logo von Setup Paydee

Setup Paydee

Community
afu-it
setup-paydee

Set up, build, debug, review, and explain Paydee payment integrations using official Paydee developer docs, the Payment Acceptance Gateway API (MPI) spec v5.0.0, per-session RSA key exchange (mkReq), hosted payment page (mercReq), non-hosted requests (mpReq), Get Payment Channels, SHA256withRSA MPI_MAC signing and verification, Inquiry, Void, Refund, PreAuth and Sales Complete, recurring and installment (split payment), response and referral codes, payment status values, sandbox test cards, and merchant onboarding. Use when working with Paydee Malaysia, FPX, e-wallets (Boost, GrabPay, ShopeePay, TNG), DuitNow QR, Visa/Mastercard with EMV 3DS, Trade Credit, callback or redirect verification, status requery, or production readiness.

Übersicht

Herausgeberafu-it
Repositorymalaysia-payment-gateway
Skill-Namesetup-paydee
Sterne
74
Forks
11
Mitgelieferte Dateien
5
Links
  • Anweisungen in Markdown

    Eine SKILL.md-Datei, die das Modell bei Bedarf lädt. So werden nur dann Token verbraucht, wenn eine Anfrage tatsächlich dazu passt.

  • Funktioniert mit jedem LLM

    KI-Skills bestehen aus reinem Markdown, nicht aus anbieterspezifischem Code. Daher funktionieren sie mit GPT, Claude, Gemini, Grok oder einem lokalen Modell.

  • 5 mitgelieferte Dateien

    Skripte, Vorlagen und Referenzmaterial, die das Modell bei der Arbeit lesen kann. Die Dateien sind schreibgeschützt und werden niemals ausgeführt.

  • Open Source

    Von afu-it auf GitHub veröffentlicht. Prüfen Sie den Quellinhalt vor der Installation.

Installation

Installieren Sie den KI-Skill Setup Paydee in TypingMind, um ihn mit jedem LLM zu nutzen, oder fügen Sie ihn einem anderen Agenten hinzu, der SKILL.md lesen kann.

1

In TypingMind installieren

TypingMind installiert einen Skill direkt aus seinem GitHub-Ordner — liest SKILL.md, bündelt die Ressourcendateien und speichert das Ergebnis lokal.

  1. Öffnen Sie die App und gehen Sie zu Plugins → Skills.
  2. Wählen Sie „Von GitHub installieren“.
  3. Fügen Sie die unten angegebene URL des Skill-Ordners ein und bestätigen Sie.
    https://github.com/afu-it/malaysia-payment-gateway/tree/main/setup-paydee
  4. Aktivieren Sie den Skill in jedem Chat, in dem er verfügbar sein soll.
Plugins → Skills → Skill anlegen → Über GitHub-URL. Fügen Sie dann die Ordner-URL ein und klicken Sie auf „Weiter“.
2

In einem anderen Agenten installieren

Jeder Agent, der das Agent-Skills-Format lesen kann, kann diesen Skill nutzen — kopieren Sie den Ordner in das Skill-Verzeichnis des jeweiligen Agenten.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/afu-it/malaysia-payment-gateway.git /tmp/malaysia-payment-gateway
mkdir -p .claude/skills
cp -r /tmp/malaysia-payment-gateway/setup-paydee .claude/skills/setup-paydee
Starten Sie Claude Code nach dem Kopieren neu, damit der neue Skill erkannt wird.

In TypingMind verwenden

Aktivieren Sie Setup Paydee in einem beliebigen Chat in TypingMind. Den Rest übernimmt das Modell. Name und Beschreibung des Skills stehen im System-Prompt. Sobald eine Anfrage passt, lädt das Modell selbstständig die vollständigen Anweisungen — Sie müssen den Skill nie manuell aufrufen, und er verbraucht erst Token, wenn er tatsächlich genutzt wird.

Das Modell lädt Setup Paydee automatisch, sobald eine passende Anfrage gestellt wird.

Funktioniert mit jedem KI-Modell

KI-Skills bestehen aus reinen Markdown-Anweisungen statt aus anbieterspezifischem Code. Daher ist Setup Paydee nicht an das Modell gebunden, für das der Skill geschrieben wurde. Installieren Sie ihn einmal in TypingMind und nutzen Sie ihn mit GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder einem selbst betriebenen lokalen Modell — alles mit Ihren eigenen API-Keys.

  • Wird nur bei Bedarf geladen

    Der System-Prompt enthält nur den Namen und die Beschreibung. Die Anweisungen werden bei der ersten passenden Anfrage geladen. Ein ungenutzter Skill verursacht daher keine Kosten.

  • Modell im laufenden Chat wechseln

    Da der Skill aus Anweisungen statt aus Code besteht, funktioniert er auch nach einem Modellwechsel — das nächste Modell liest dieselbe SKILL.md-Datei.

Skill-Anweisungen

Dies ist der Inhalt von SKILL.md, den das Modell lädt. Lesen Sie ihn vor der Installation — ein Skill besteht aus Anweisungen, denen Ihr Modell folgt.

Paydee Payment Gateway

Use this skill for Paydee (Paydee Sdn Bhd, formerly Synergy Cards) Payment Acceptance Gateway integration work. Paydee calls the merchant-facing API the "MPI" (Merchant Plug-In) server.

Source

Read references/paydee-api.md before giving factual API guidance or writing integration code. It holds the endpoint catalogue, environments, key exchange, request and response field tables, the exact MAC string-to-sign orders, status and error codes, void/refund rules, recurring fields, test cards, and documented conflicts between official sources.

Read references/paydee-codes.md when mapping any errorCode, MPI_ERROR_CODE, MPI_REFERRAL_CODE, MPI_AUTH_STATUS, or MPI_STATUS_REASON value.

Read references/account-setup.md when the user asks how to become a merchant, where credentials come from, sandbox versus production access, RSA key enrollment, payment method activation, settlement, or pricing.

Read references/source-map.md to pick the right official page or file (developer site, spec PDF, Swagger JSON, message-table XLSX) and to see what could not be read.

Core Workflow

  1. Identify environment: test (https://devlink.paydee.co/mpi, from Paydee's published Swagger) or production (endpoint released by Paydee after login/onboarding).
  2. Identify surface: hosted payment page (/mercReq, Paydee renders checkout) or non-hosted (/mpReq, merchant page, plus all server-side INQ/VSALES/REFUND/RECURR/TERMINATE/SALESCOMPL calls).
  3. Create a local pending payment with a new unique transaction ID (max 20 chars, minimum 6 digits; all-digit IDs are safest because the request tables type it N) before any Paydee call.
  4. Generate a fresh RSA-2048 key pair for this payment session. Call POST /mkReq (JSON) with merchantId, purchaseId (= the transaction ID), pubKey (Base64Url), optional paymentMethod, and mac if key-exchange MAC is enrolled. Store Paydee's returned session pubKey.
  5. Build the MPI_* form fields, compute MPI_MAC = Base64Url(SHA256withRSA(merchant session private key, concatenated values in the documented order)).
  6. Hosted: auto-post the form from the cardholder browser to /mercReq. Non-hosted SALES: post to /mpReq with MPI_PAYMENT_CHANNEL_ID from /channels.
  7. On the redirect and on the callback, verify the response MPI_MAC with Paydee's session public key over the documented response field order before trusting any field.
  8. Settle only when MPI_MERC_ID, MPI_TRXN_ID, amount and currency match the local record, MPI_ERROR_CODE is 000 and MPI_STATUS is 1 (Payment Success, or 7 Payment Settled on a later INQ). Make settlement idempotent.
  9. If no response, timeout, or browser closed: run INQ (new key exchange, new transaction ID, MPI_ORI_TRXN_ID = original) before retrying a sale.
  10. Void before cut-off, otherwise refund; both are asynchronous, so confirm with INQ (Paydee suggests about 30 minutes later) and read MPI_STATUS.

Core Facts

  • Every API call is HTTPS POST except Get Payment Channels (GET /channels, JSON body per spec).
  • Endpoints: /mkReq (key exchange, JSON), /mercReq (hosted page, form data), /mpReq (non-hosted and server operations, form data application/x-www-form-urlencoded), /channels (channel list).
  • Test server in the official Swagger: https://devlink.paydee.co/mpi. Production URL is locked behind developer-portal login.
  • Key exchange must precede every other call. purchaseId in /mkReq equals MPI_TRXN_ID in the next request; each new operation (INQ, VOID, REFUND, RECURR) uses a new ID and its own key exchange.
  • Signature: SHA256withRSA, Base64Url encoded, signed with the sender's private key, verified with the peer's public key exchanged in /mkReq.
  • Amounts are integers in minor units (MYR 10.23 = 1023); currency is ISO 4217 numeric (458 = MYR). The XLSX says Paydee only accepts MYR.
  • MPI_PURCH_DATE is yyyyMMddHHmmss (24h).
  • MPI_EMAIL is mandatory; billing address is conditional (C1); at least one phone pair is required (C2). Visa rules effective 12 Feb 2024 drive these.
  • Payment methods (paymentMethod / MPI_CUST_PAYMENT_METHOD): CC, EWALLETS, FPX, TRD (Trade Credit), DNQR (DuitNow QR).
  • MPI_STATUS: 0 requested, 1 success, 2 cancelled, 3/4 reverse requested/success, 5/6 refund requested/success, 7 settled, 8 recurring terminated, -1 failed, -2 reverse failed, -3 refund failed, -4 sales request failed.
  • Paydee asks that the checkout page be implemented in an iframe per EMV 3-D Secure 2.0.
  • SALESCOMPL is rejected if the final amount exceeds the PREAUTH amount by more than 20%.
  • Online banking (FPX) refund function was removed in spec v3.0.3 (1 July 2025).
  • Published sandbox test cards: Visa 4100000000000100, Mastercard 5100000000000107 (frictionless success); challenge cards use OTP 123456. Sandbox only.

Critical Rules

  • Keep RSA private keys server-side. Never send card data from a non-PCI server; non-hosted card fields (MPI_PAN, MPI_CVV2) put you in PCI DSS scope.
  • Never mark paid from the browser redirect alone; verify MPI_MAC on both redirect and callback, and use INQ as the authority when in doubt.
  • Build the MAC string from exactly the documented field order, using empty strings for absent fields. Confirm whitespace handling with Paydee (samples show spaces removed).
  • Verify with the Paydee public key from the same session's /mkReq response, not a cached key from another session.
  • Treat 004 (in processing) and void/refund acknowledgements as non-final.
  • Never reuse a transaction ID; a duplicate is rejected (594) and the pair (merchant ID, transaction ID) identifies the transaction.
  • Keep test and production merchant IDs, keys and endpoints separate.

Completion Criteria

A Paydee integration is done only when:

  1. Each payment session generates its own RSA key pair and runs /mkReq server-side; Paydee's session key is stored with the payment.
  2. Request MPI_MAC is produced over the documented order and accepted by the test server (no 5A0).
  3. Redirect and callback handlers verify response MPI_MAC, merchant ID, transaction ID, amount and currency before settlement.
  4. Settlement requires MPI_ERROR_CODE=000 and MPI_STATUS=1, is idempotent, and handles duplicates.
  5. INQ fallback exists for timeout, closed browser and pending states; void/refund outcomes are confirmed by INQ.
  6. Non-hosted flows load /channels and disable blocked (=B) channels.
  7. Tests cover bad MAC, wrong amount, wrong transaction ID, failed card (4100000000300005), challenge flow, and duplicate callback.
  8. Deployment docs list PAYDEE_ENV, PAYDEE_ENDPOINT, PAYDEE_MERCHANT_ID, enrolled key-exchange key path (if used), and the callback/redirect URL agreed with Paydee.

Loophole Review Loop

When asked whether a Paydee strategy is "100% confident", run this loop until no factual gaps remain:

  1. List trust boundaries: cardholder browser, hosted page, merchant checkout page, /mkReq caller, key store, MAC builder, callback receiver, redirect handler, INQ job, void/refund job, recurring scheduler, database.
  2. Check bypasses: forged redirect, MAC verified against the wrong session key, MAC string built with wrong order or whitespace, missing empty fields, reused transaction ID, amount in ringgit instead of sen, test/production mix, trusting 004, trusting a void/refund ack, blocked channel shown as selectable, SALESCOMPL above 120%, recurring sent without original transaction ID.
  3. Add fixes: per-session keys, strict field order, constant-format amount, server-side INQ confirmation, idempotency key on (merchant_id, trxn_id), durable callback log, separate env config.
  4. Re-read references/paydee-api.md sections relevant to any gap, especially "Documented conflicts".
  5. State remaining uncertainty: callback URL setup, production endpoint, recurring field names, whitespace in MAC string, response MAC order, and IP allowlists are not fully specified in public docs and must be confirmed with Paydee (help@paydee.co).

Mitgelieferte Dateien

Das Modell liest diese Dateien bei Bedarf, während der Skill geladen ist. Sie werden als lesbare Dateien bereitgestellt und niemals ausgeführt.

Häufig gestellte Fragen

Was macht der KI-Skill Setup Paydee?

Set up, build, debug, review, and explain Paydee payment integrations using official Paydee developer docs, the Payment Acceptance Gateway API (MPI) spec v5.0.0, per-session RSA key exchange (mkReq), hosted payment page (mercReq), non-hosted requests (mpReq), Get Payment Channels, SHA256withRSA MPI_MAC signing and verification, Inquiry, Void, Refund, PreAuth and Sales Complete, recurring and installment (split payment), response and referral codes, payment status values, sandbox test cards, and merchant onboarding. Use when working with Paydee Malaysia, FPX, e-wallets (Boost, GrabPay, Shope...

Warum Setup Paydee in TypingMind nutzen?

Weil Sie den Skill einmal installieren und mit jedem Modell verwenden können. Setup Paydee besteht aus reinem Markdown statt aus anbieterspezifischem Code. So funktioniert derselbe Skill mit GPT-5, Claude, Gemini, Grok oder einem lokalen Modell – und Sie können das Modell mitten im Chat wechseln, ohne dass der Skill seine Funktion verliert. TypingMind verwendet Ihre eigenen API-Schlüssel. Sie bezahlen die Anbieter daher direkt statt über ein Abonnement pro Nutzerplatz, und Ihre Skills und Chats bleiben in Ihrem eigenen Speicher.

Wie installiere ich Setup Paydee in TypingMind?

Öffnen Sie in TypingMind Plugins → Skills → Von GitHub installieren und fügen Sie https://github.com/afu-it/malaysia-payment-gateway/tree/main/setup-paydee ein. TypingMind liest die Datei SKILL.md, bündelt die zugehörigen Dateien und installiert alles als Skill, den Sie für jeden Chat einzeln aktivieren können.

Welche KI-Modelle können Setup Paydee nutzen?

Jedes Modell, das Sie in TypingMind verbinden. KI-Skills bestehen aus reinen Markdown-Anweisungen statt aus anbieterspezifischem Code. Daher können GPT, Claude, Gemini, Grok und lokale Modelle diesen Skill laden, wenn eine Anfrage dazu passt.

Wie viele KI-Modelle kann ich mit Setup Paydee verwenden?

So viele Sie möchten. Solange ein Modell Skills unterstützt, können Sie Setup Paydee damit verwenden – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama und weitere – alles in TypingMind mit Ihren eigenen API-Schlüsseln.

Ist der KI-Skill Setup Paydee kostenlos?

Der Skill wird von afu-it auf GitHub veröffentlicht. Die Lizenzbedingungen finden Sie im Repository. Sie bezahlen nur Ihren eigenen KI-Anbieter für die verwendeten Token.

Was sind KI-Skills?

Ein KI-Skill ist ein wiederverwendbares Anweisungspaket, das einem KI-Modell vermittelt, wie es eine bestimmte Aufgabe erledigt. Es folgt dem offenen Format Agent Skills: eine Datei namens SKILL.md mit einem Namen und einer Beschreibung sowie allen Skripten, Vorlagen oder Referenzdateien, die das Modell möglicherweise benötigt. Das Modell liest die Anweisungen nur, wenn Ihre Anfrage zum Skill passt. Ein installierter Skill verursacht daher erst Kosten, wenn er verwendet wird.

Wie unterscheiden sich KI-Skills von Plugins oder MCP-Servern?

Ein Plugin oder MCP-Server stellt einem Modell neue aufrufbare Tools bereit – Code, der auf einem System ausgeführt wird und ein Ergebnis zurückgibt. Ein KI-Skill vermittelt dem Modell stattdessen Wissen und Vorgehensweisen: wie es eine Aufgabe angeht, welche Schritte es befolgt und wie eine gute Ausgabe aussieht. Skills bestehen aus reinem Markdown und benötigen daher weder Server noch API-Schlüssel oder Laufzeitumgebung. Sie funktionieren mit jedem Modell.

Alle

Jetzt eigenen KI-Arbeitsbereich einrichten

Abonnieren Sie unseren Newsletter und erfahren Sie mehr über neue Funktionen und kommende Gewinnspiele 👇