Setup Revenue Monsterのロゴ

Setup Revenue Monster

コミュニティ
afu-it
setup-revenue-monster

公式Revenue MonsterドキュメントとSDK、OAuth 2.0クライアント認証情報、RSA SHA256リクエスト署名(X-Signature、X-Nonce-Str、X-Timestamp)、ホスト型Web Paymentチェックアウト(v3/payment/online)、Direct Payment Checkout、notify URLコールバック、リダイレクト処理、注文IDによる取引照会、返金、取消、取引照合、トークン化、定期決済、サンドボックス/本番環境の設定、Merchant Portalの認証情報を使って、Revenue Monster決済連携の設定、構築、デバッグ、レビュー、説明を行います。Revenue Monster(RM)Malaysia、FPX、DuitNow QR、カード、Apple Pay、Google Pay、TNG、Boost、GrabPay、ShopeePay、Alipay+、WeChat Pay、チェックアウトのリダイレクト、notifyによる精算、INVALID_REQUEST_SIGNATUREエラー、返金、本番環境への移行準備に関する作業で使用してください。

Add to TypingMind

概要

公開者afu-it
リポジトリmalaysia-payment-gateway
スキル名setup-revenue-monster
スター
74
フォーク
11
同梱ファイル
9
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 9個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    afu-itがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキル「Setup Revenue Monster」をTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/afu-it/malaysia-payment-gateway/tree/main/setup-revenue-monster
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

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-revenue-monster .claude/skills/setup-revenue-monster
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでSetup Revenue Monsterを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあるとすぐに、モデルが自動的にSetup Revenue Monsterを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Setup Revenue Monsterは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、スキルを使わない間は指示の読み込みにトークンを消費しません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

Revenue Monster Payment Gateway

Use this skill for Revenue Monster (RM) Open API payment integration work.

Source

Read references/revenue-monster-api.md before giving factual API guidance or writing integration code. It contains environments, OAuth token flow, the RSA signature algorithm with exact string-to-sign, hosted checkout fields, redirect and notify payloads, query, refund, reverse, reconciliation, methods, statuses, and error codes.

It also holds the Endpoint Catalogue (every documented operation) and points to the detail files:

  • references/revenue-monster-objects.md: Transaction Object, nested objects, type/status enums, method and region matrix, FPX B2C/B2B bank codes.
  • references/revenue-monster-tokenization.md: recurring, tokenized customer, charge bound card, card-on-file tokens.
  • references/revenue-monster-instore.md: Quick Pay, terminal events, POS, Android deeplink.
  • references/revenue-monster-invoice.md: invoice / payment link API (/api/v3/...).
  • references/revenue-monster-errors.md: every documented error code.

Read references/account-setup.md when the user asks how to register, where Client ID / Client Secret / Store ID / RSA keys live, sandbox activation, payment method activation, env var names, pricing, or plugins.

Read references/source-map.md when choosing which official RM docs page or SDK file applies.

Core Workflow

  1. Identify environment: sandbox (sb-oauth, sb-open) or production (oauth, open).
  2. Identify integration surface: hosted Web Payment checkout, Mobile Payment, Direct Payment Checkout (own UI, QR, FPX bank, card native), Quick Pay (POS scan), tokenization/recurring, low-code button, or plugin.
  3. Confirm Merchant Portal setup: application Client ID and Client Secret, your RSA public key uploaded, RM server public key saved, Store ID, and activated payment methods.
  4. Get an access token server-side with POST /v1/token (Basic auth of clientId:clientSecret, grantType: client_credentials); cache it and refresh before expiry.
  5. Create a local pending payment with a unique order.id (max 24 chars) and amount in sen before calling RM.
  6. Call POST /v3/payment/online with Bearer token plus X-Signature, X-Nonce-Str, X-Timestamp; redirect the customer to item.url.
  7. Treat redirectUrl (?status=&orderId=) as browser UX only.
  8. On notify (eventType: PAYMENT_WEB_ONLINE), record the payload, then requery GET /v3/payment/transaction/order/{orderId} with a signed request.
  9. Settle idempotently only when the queried transaction is SUCCESS and order.id, order.amount, currencyType, store, and environment match.
  10. Run a requery job for pending orders, because notify fires only on success and may be missed.

Core Facts

  • OAuth: https://oauth.revenuemonster.my/v1/token; sandbox https://sb-oauth.revenuemonster.my/v1/token.
  • Open API: https://open.revenuemonster.my; sandbox https://sb-open.revenuemonster.my. Payment APIs are under /v3.
  • Hosted checkout: POST /v3/payment/online, type WEB_PAYMENT or MOBILE_PAYMENT, layoutVersion v4.
  • Amounts are integers in sen (100 = RM 1.00); minimum RM 0.10; currency MYR only.
  • Signature: RSA PKCS#1 v1.5 with SHA-256 over data=<b64>&method=<lower>&nonceStr=<n>&requestUrl=<url>&signType=sha256&timestamp=<unix>, where <b64> is Base64 of key-sorted, compact JSON with <, >, & escaped as \u003c, \u003e, \u0026.
  • Header format: X-Signature: sha256 <base64signature>. Nonce must be unique for 120 seconds; timestamp is UTC Unix seconds within 120 seconds of server time.
  • Empty body (GET): omit the data= pair. Verifying RM's callback: requestUrl can be skipped; verify with the RM server public key.
  • Redirect statuses: SUCCESS, FAILED, CANCELLED, EXPIRED.
  • Notify is sent only on successful payment; failures and refunds do not trigger notify.
  • Transaction statuses: SUCCESS, FAILED, IN_PROCESS, FULL_REFUNDED, PARTIAL_REFUNDED, REVERSED.
  • Refund: POST /v3/payment/refund with transactionId, refund.type FULL, refund.currencyType, refund.amount, reason.
  • Reverse (timeouts, about 15 minutes): POST /v3/payment/reverse with orderId.
  • Credentials live in Merchant Portal > Developer > Applications.

Critical Rules

  • Keep Client Secret, access/refresh tokens, and your RSA private key server-side only.
  • Never mark paid from redirectUrl query params or the notify body alone; settle from a signed server-side query.
  • Sign the exact requestUrl you call, including any query string, and lowercase the HTTP method.
  • Sort JSON keys recursively and compact before Base64; a mismatch returns INVALID_REQUEST_SIGNATURE (sandbox returns a debug object showing each step).
  • Generate a fresh 32-character nonce and fresh timestamp per request; reused nonces cause duplicate request errors.
  • Use sandbox keys, tokens, Store ID, and server public key only with sandbox hosts; never mix environments.
  • Keep order.id unique per attempt (ORDER_ID_DUPLICATE otherwise) and store checkoutId and transactionId.
  • If a payment call times out, reverse by orderId before retrying with a new order to avoid double charge.
  • Make notify handling and refunds idempotent; check balanceAmount before refunding.
  • Verify live method activation (for example BOOST_MALAYSIA_NOT_ACTIVE), pricing, and settlement in the portal before claiming production certainty.

Completion Criteria

A Revenue Monster integration is done only when:

  1. Token fetch, caching, and refresh run server-side with Basic auth of Client ID and Secret.
  2. Every Open API call carries Bearer token, X-Signature, X-Nonce-Str, X-Timestamp, and passes in sandbox.
  3. Hosted checkout is created server-side with amount in sen and a unique order.id; the customer goes to item.url.
  4. Redirect handler shows status only and triggers a requery; it does not fulfil.
  5. Notify handler records the payload, requeries the transaction by order ID, and settles only on SUCCESS with matching amount, currency, order ID, and store.
  6. Duplicate notify, missing notify, failed/expired/cancelled checkouts, and refunds are idempotent and tested.
  7. Tests cover signature string building (sorted JSON, escapes, empty body), wrong amount/order, duplicate notify, and timeout reverse.
  8. Deployment docs list RM_CLIENT_ID, RM_CLIENT_SECRET, RM_PRIVATE_KEY, RM_SERVER_PUBLIC_KEY, RM_STORE_ID, env, redirect URL, and notify URL.

Loophole Review Loop

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

  1. List trust boundaries: browser redirect, checkout page, backend checkout creator, OAuth server, Open API, notify receiver, signature builder, key storage, database, fulfilment job, refund job, Merchant Portal settings, and method activation.
  2. Check bypasses: fake redirect status=SUCCESS, forged notify body, notify missing (fires on success only), signature over unsorted or unescaped JSON, wrong requestUrl, uppercase method, stale timestamp, reused nonce, sandbox/live key mix, expired access token, wrong amount (ringgit vs sen), reused order ID, timeout double charge, duplicate refund, refund outside provider window, and inactive method.
  3. Add fixes: server-side checkout, local pending payment first, signed requery before settlement, strict amount/currency/order/store checks, durable notify log, idempotency keys, token cache with refresh, reverse on timeout, separate environment config, and portal capability checks.
  4. Re-read references/revenue-monster-api.md sections relevant to any gap.
  5. State remaining uncertainty if it depends on notify header names, method activation, refund windows, pricing, settlement timing, or merchant approval.

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Setup Revenue Monster」では何ができますか?

公式Revenue MonsterドキュメントとSDK、OAuth 2.0クライアント認証情報、RSA SHA256リクエスト署名(X-Signature、X-Nonce-Str、X-Timestamp)、ホスト型Web Paymentチェックアウト(v3/payment/online)、Direct Payment Checkout、notify URLコールバック、リダイレクト処理、注文IDによる取引照会、返金、取消、取引照合、トークン化、定期決済、サンドボックス/本番環境の設定、Merchant Portalの認証情報を使って、Revenue Monster決済連携の設定、構築、デバッグ、レビュー、説明を行います。Revenue Monster(RM)Malaysia、FPX、DuitNow QR、カード、Apple Pay、Google Pay、TNG、Boost、GrabPay、ShopeePay、Alipay+、WeChat Pay、チェックアウトのリダイレクト、notifyによる精算、INVALID_REQUEST_SIGNATUREエラー、返金、本番環境への移行準備に関する作業で使用してください。

TypingMindでSetup Revenue Monsterを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Setup Revenue Monsterはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにSetup Revenue Monsterをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/afu-it/malaysia-payment-gateway/tree/main/setup-revenue-monsterを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Setup Revenue Monsterを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストの内容がこのスキルの用途に合ったときに、このスキルを読み込めます。

Setup Revenue Monsterで使えるAIモデルの数に制限はありますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもSetup Revenue Monsterを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Setup Revenue Monster」は無料ですか?

afu-itがGitHubで公開しています。ライセンス条件はリポジトリでご確認ください。ご利用のAIプロバイダーに支払うのは、使用したトークンの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇