Logo von Setup Paypal

Setup Paypal

Community
afu-it
setup-paypal

Set up, build, debug, review, and explain PayPal payment integrations for Malaysian merchants using official PayPal developer docs, REST API OAuth 2.0, Orders v2 create/capture/authorize, Payments v2 refunds/voids/reauthorization, JavaScript SDK v6 and v5 buttons, webhooks with CRC32 plus SHA256withRSA signature verification or verify-webhook-signature postback, Subscriptions and Catalog Products, Transaction Search, Payouts, disputes, sandbox accounts, test cards, negative testing, MYR rules, and go-live. Use when working with PayPal Checkout, PayPal buttons, PayPal REST APIs, MYR payments, cross-border sales from Malaysia, PayPal webhooks, PayPal recurring billing, refunds, reconciliation, or production readiness.

Übersicht

Herausgeberafu-it
Repositorymalaysia-payment-gateway
Skill-Namesetup-paypal
Sterne
74
Forks
11
Mitgelieferte Dateien
10
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.

  • 10 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 Paypal 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-paypal
  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-paypal .claude/skills/setup-paypal
Starten Sie Claude Code nach dem Kopieren neu, damit der neue Skill erkannt wird.

In TypingMind verwenden

Aktivieren Sie Setup Paypal 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 Paypal 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 Paypal 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.

PayPal Payment Gateway (Malaysia)

Use this skill for PayPal integration work for a Malaysia-registered PayPal Business account.

Source

Read references/paypal-api.md first. It has the Malaysia scope summary, environments, auth, headers, amount rules, the default checkout flow, statuses, and the full endpoint catalogue.

Then load only what the task needs:

  • references/paypal-orders.md: Orders v2 and Payments v2 field tables, capture checks, PATCH, refunds.
  • references/paypal-webhooks.md: signature verification, headers, events, Webhooks Management API.
  • references/paypal-checkout-js.md: JavaScript SDK v6 and v5, callbacks, server routes.
  • references/paypal-subscriptions.md: products, plans, subscriptions, failure retry.
  • references/paypal-errors-testing.md: error codes, sandbox, test cards, negative testing.
  • references/paypal-reporting-payouts.md: Transaction Search, Payouts (MYR rules), disputes.
  • references/account-setup.md: registration, credentials, env vars, dashboard settings, Malaysian account notes, pricing link.
  • references/source-map.md: which official page backs each fact, coverage, and known gaps.

Core Workflow

  1. Identify environment (sandbox or live) and use matching credentials, host, client ID and Webhook ID.
  2. Identify surface: JS SDK buttons (v6 for new work), server redirect to the approval link, Subscriptions, Payment Links, or Payouts.
  3. Create a local pending payment with amount, MYR (or the chosen currency) and your reference.
  4. Server: get an OAuth token (cache it), then POST /v2/checkout/orders with intent: CAPTURE, custom_id/invoice_id, and a PayPal-Request-Id.
  5. Browser: buyer approves through the SDK or the approve / payer-action link.
  6. Server: POST /v2/checkout/orders/{id}/capture with a PayPal-Request-Id.
  7. Settle only when purchase_units[].payments.captures[].status is COMPLETED and amount, currency and reference match.
  8. Verify every webhook signature over the raw body, deduplicate by event id, re-fetch the order or capture, then settle idempotently.
  9. Handle PENDING captures, INSTRUMENT_DECLINED, reversals, refunds and disputes.

Core Facts

  • REST base: sandbox https://api-m.sandbox.paypal.com, live https://api-m.paypal.com.
  • Token: POST /v1/oauth2/token, Basic auth client_id:secret, body grant_type=client_credentials; use Authorization: Bearer <token> until expires_in.
  • Orders: POST /v2/checkout/orders, GET /v2/checkout/orders/{id}, POST /v2/checkout/orders/{id}/capture, /authorize, PATCH /v2/checkout/orders/{id}.
  • Payments: POST /v2/payments/captures/{id}/refund, GET /v2/payments/captures/{id}, authorization capture, void, reauthorize.
  • Amounts are decimal strings in {"currency_code","value"}; not sen.
  • MYR is supported as payment and balance currency for in-country (Malaysian) PayPal accounts only.
  • Order COMPLETED can still hold a declined payment; check the capture status.
  • Webhook self-verify string: transmission_id|transmission_time|webhook_id|crc32(raw body, decimal), verified with the cert at paypal-cert-url (SHA256withRSA). Postback: POST /v1/notifications/verify-webhook-signature must return verification_status: SUCCESS.
  • Webhook retries: up to 25 times over 3 days for non-2xx. Up to 10 webhook URLs per app.
  • JS SDK v6: https://www.paypal.com/web-sdk/v6/core (sandbox https://www.sandbox.paypal.com/web-sdk/v6/core). v5: https://www.paypal.com/sdk/js?client-id=...&currency=MYR.
  • Authorization: 29-day validity, 3-day honor period. Refund within 180 days of capture.
  • No published rate limit; 429 RATE_LIMIT_REACHED on abuse. Use webhooks, not polling.
  • Not available to Malaysian merchants per the docs: FPX, DuitNow, local e-wallets, Expanded Checkout card fields, card vaulting, Pay Later, PayPal Credit, Venmo. GrabPay via PayPal is Singapore only.

Critical Rules

  • Keep the client secret server-side. Only the client ID goes to the browser.
  • Create and price orders on the server; never trust amounts sent by the browser.
  • Never fulfil from onApprove, a redirect to return_url, or a browser-sent status.
  • Verify webhooks over the raw body bytes with the Webhook ID of the same environment; never re-serialize JSON before CRC32 or postback.
  • Use PayPal-Request-Id on create, capture, authorize and refund; reuse the same ID when retrying a timeout or 5xx.
  • Treat ORDER_ALREADY_CAPTURED as "fetch and settle", not as failure.
  • Keep invoice_id unique per order; duplicates are rejected by default.
  • Match SDK currency and intent to the API order.
  • Set Payment Receiving Preferences so MYR or foreign-currency payments do not sit pending for manual acceptance.
  • Do not use the API for personal payments in Malaysia (PayPal policy).
  • Do not claim local Malaysian methods or Expanded Checkout features for a Malaysian account.

Completion Criteria

A PayPal integration is done only when:

  1. Orders are created and captured server-side with cached OAuth tokens and PayPal-Request-Id.
  2. The browser only returns the order ID; the server decides paid state from the capture response or a verified webhook.
  3. Webhooks are subscribed per environment and verified (self or postback) over the raw body.
  4. Settlement checks order ID, capture ID, capture status, amount, currency, custom_id/invoice_id and environment.
  5. Duplicate webhooks, capture retries, pending captures, reversals and refunds are idempotent.
  6. Tests cover bad signature, replayed event, INSTRUMENT_DECLINED, pending capture, duplicate invoice ID, partial and over refund.
  7. Deployment docs list PAYPAL_CLIENT_ID, PAYPAL_CLIENT_SECRET, PAYPAL_WEBHOOK_ID, API base, webhook URL and sandbox/live separation.

Loophole Review Loop

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

  1. List trust boundaries: browser SDK, return/cancel URLs, server order creator, OAuth token cache, PayPal API, webhook receiver, raw-body parser, cert download, database, fulfilment, refund job, dashboard settings.
  2. Check bypasses: fake onApprove, client-sent amount, forged webhook, re-serialized body, wrong environment Webhook ID, sandbox/live mix, COMPLETED order with declined capture, pending capture fulfilled, duplicate webhook, capture retry without idempotency key, MYR pending manual acceptance, reversal after fulfilment, duplicate refund, cert URL from a non-PayPal host.
  3. Add fixes: server-side pricing, local pending record, capture-status checks, raw-body verification, event ID dedupe, PayPal-Request-Id, environment-scoped config, re-fetch before settle, reversal and dispute handlers.
  4. Re-read the relevant reference file for any gap.
  5. State remaining uncertainty that depends on account eligibility, receiving preferences, fees, PayPal-wallet vaulting for Malaysia, or undocumented fields listed in references/source-map.md.

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 Paypal?

Set up, build, debug, review, and explain PayPal payment integrations for Malaysian merchants using official PayPal developer docs, REST API OAuth 2.0, Orders v2 create/capture/authorize, Payments v2 refunds/voids/reauthorization, JavaScript SDK v6 and v5 buttons, webhooks with CRC32 plus SHA256withRSA signature verification or verify-webhook-signature postback, Subscriptions and Catalog Products, Transaction Search, Payouts, disputes, sandbox accounts, test cards, negative testing, MYR rules, and go-live. Use when working with PayPal Checkout, PayPal buttons, PayPal REST APIs, MYR payments...

Warum Setup Paypal in TypingMind nutzen?

Weil Sie den Skill einmal installieren und mit jedem Modell verwenden können. Setup Paypal 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 Paypal 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-paypal 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 Paypal 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 Paypal verwenden?

So viele Sie möchten. Solange ein Modell Skills unterstützt, können Sie Setup Paypal 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 Paypal 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 👇