← Back to category

Documentation

QRIS Payment Gateway API Reference (ClincooPay)

ClincooPay is the built-in Clincoo payment gateway: buyers pay with QRIS, the balance lands in your project dashboard, and you can withdraw it anytime. This is the official API reference for sites deployed from app.clincoo.buzz.

Integration overview

  1. Activate Payments in your project Settings, then copy your pay_key (starts with clc_pay_).
  2. Your site calls POST /api/pay to create a QRIS transaction.
  3. The buyer is sent to the official Clincoo checkout page, or you render the QR yourself.
  4. Your site polls GET /api/pay?action=status until the payment clears.
  5. When paid, Clincoo sends a webhook to your registered URL.

Endpoint summary

EndpointPurposeAuth
POST /api/pay {action:"create"}Create a new QRIS transactionpay_key (public)
GET /api/pay?action=statusCheck transaction statuspay_key (public)
POST /api/pay {action:"activate"}Activate the gateway for a projectClincoo login
GET /api/pay?action=configStatus, pay_key, and balanceClincoo login
POST /api/pay {action:"withdraw"}Request a balance withdrawalClincoo login
POST /api/pay {action:"transactions"}Last 25 transactionsClincoo login

All endpoints live at https://app.clincoo.buzz/api/pay. The pay_key is safe to use in your frontend — it can only create transactions and read status; the real gateway credentials stay on Clincoo servers.

Creating a QRIS transaction

Send a POST request from your deployed site — no login needed:

POST https://app.clincoo.buzz/api/pay
Content-Type: application/json

{
  "action": "create",
  "key": "clc_pay_....",
  "amount": 25000,
  "description": "Plan A"
}

Parameters:

FieldRequiredNotes
keyYesYour project pay_key, e.g. clc_pay_....
amountYesInteger rupiah, Rp 1,000 to Rp 100,000,000
descriptionNoTransaction note, up to 100 characters

Example success response:

{
  "success": true,
  "order_id": "clincoo....",
  "checkout_url": "https://app.clincoo.buzz/pay/?order_id=clincoo....&key=clc_pay_....",
  "amount": 25000,
  "qr_image": "https://api.qrserver.com/v1/create-qr-code/?...",
  "qr_string": "<QRIS payload>",
  "total_payment": 25415,
  "expires_at": "2026-10-03T09:00:00.000Z",
  "is_sandbox": false
}

total_payment is what the buyer actually pays (amount + QRIS fee). A 503 gateway_not_ready response means the QRIS server is still activating — surface that message as-is.

Easiest path: use the official checkout

After a successful create, simply send the buyer to checkout_url. The official Clincoo checkout page shows the QR, the total bill, automatic status checks, and a success page — you do not need to build your own checkout.

async function createPayment(amount) {
  const r = await fetch('https://app.clincoo.buzz/api/pay', {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({ action: 'create', key: 'clc_pay_....', amount, description: 'Payment' })
  });
  const d = await r.json();
  if (d.success) window.location.href = d.checkout_url;
}

If you want a custom checkout instead: display qr_image in an img tag (or render qr_string yourself), then poll for status as below.

Checking transaction status

GET https://app.clincoo.buzz/api/pay?action=status&key=clc_pay_....&order_id=clincoo....

{ "success": true, "status": "paid", "amount": 25000, "total_payment": 25415 }

Possible status values:

StatusMeaning
pendingAwaiting payment; the QR is still active
paidCleared — balance added to your project dashboard
expiredQR expired or canceled

Poll every 3-5 seconds until the status is paid, then show your success page. The server checks the gateway at most once every 4 seconds per transaction, so faster polling returns nothing new.

Payment webhook

Whenever a transaction becomes paid, Clincoo POSTs a notification to your project webhook URL (register it under Settings > Webhook):

{
  "event": "payment.paid",
  "order_id": "clincoo....",
  "amount": 25000,
  "description": "Plan A",
  "status": "paid",
  "paid_at": "2026-10-03T09:00:00.000Z"
}

Always match the order_id against your system before fulfilling the order. The buyer-facing success page still lives on your site.

Owner dashboard

These actions require a Clincoo login and a project_id field:

ActionResult
configActive status, pay_key, available balance, total paid, total withdrawn
summaryShort balance summary
transactionsLast 25 transactions
withdrawWithdraw funds, minimum Rp 10,000, up to available balance
withdrawalsLast 25 withdrawal records

Everything here is also available from the Settings > Payments page in the dashboard without touching the API. Need help? See the FAQ or Common Issues.