Midtrans-Middleware
Go to file
Tengku Achmad 14c305b6bf feat: document full API surface in Postman collection
Reorganize into folders (Health & Config, Payment Links, Payment Operations,
Webhook, Logs & Docs, Dev/Test) and add every route that was missing:
GET/POST /api/config, POST /createtransaksi (ERP shape), Charge (Core API),
Create Snap Token, GET /api/logs, GET /api/logs/files, GET /api/logs/view,
GET /openapi.json, GET /docs, and the LOG_EXPOSE_API-only echo/echo2/
test-notify-erp endpoints. The Logs & Docs folder carries collection-level
Basic Auth (log_user/log_pass variables) shared by all its requests.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-03 22:49:38 +07:00
postman feat: document full API surface in Postman collection 2026-08-03 22:49:38 +07:00
public feat: update favicon and page title for branding 2025-11-22 11:58:37 +07:00
scripts Fix Snap payment flow: direct to payment UI in step 2 and add customer/item details to API request 2025-12-03 17:01:12 +07:00
server feat: add internal admin tooling — log viewer and Scalar API docs 2026-08-03 22:49:26 +07:00
src Merge branch 'main' of https://git.winteraccess.id/root/Midtrans-Middleware 2026-01-06 20:46:26 +07:00
tests fix: update webhook signature retrieval and enhance error logging; correct file path in payment link test 2025-12-08 11:58:44 +07:00
.gitignore fix: harden payment-creation endpoints and persist server state 2026-08-03 22:48:37 +07:00
README.md feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00
ecosystem.config.cjs fix: harden payment-creation endpoints and persist server state 2026-08-03 22:48:37 +07:00
eslint.config.js feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00
index.html feat: update global styles and Tailwind configuration with Inter font; remove obsolete test files and add server documentation 2025-12-04 22:57:38 +07:00
package-lock.json feat: add fs and path dependencies; update server logging and webhook handling 2025-12-05 15:05:51 +07:00
package.json feat: add fs and path dependencies; update server logging and webhook handling 2025-12-05 15:05:51 +07:00
postcss.config.cjs feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00
tailwind.config.ts feat: update global styles and Tailwind configuration with Inter font; remove obsolete test files and add server documentation 2025-12-04 22:57:38 +07:00
tsconfig.app.json feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00
tsconfig.json feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00
tsconfig.node.json feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00
vite.config.ts feat(payments): stabilisasi QRIS & CStore; hapus tombol Buat QR 2025-11-10 11:10:35 +07:00

README.md

Core Midtrans CIFO (Frontend)

Frontend Vite + React untuk integrasi Midtrans Core API dengan UI kustom.

Setup

  1. Duplikasi file contoh env dan isi nilainya:
cp .env.example .env.local

Isi .env.local (lihat .env.example untuk referensi):

VITE_API_BASE_URL=http://localhost:8000/api
VITE_MIDTRANS_CLIENT_KEY=YOUR_CLIENT_KEY
VITE_MIDTRANS_ENV=sandbox
  1. Jalankan pengembangan:
npm install
npm run dev

App akan tersedia di http://localhost:5173/ (atau port lain jika 5173 dipakai).

Catatan Integrasi Midtrans

  • Client Key hanya digunakan di frontend (mis. tokenisasi kartu/3DS). Server Key TIDAK pernah di frontend.
  • Semua request ke Midtrans dilakukan lewat backend (VITE_API_BASE_URL). Frontend memanggil endpoint seperti /payments/:orderId/status.
  • Status real-time dapat diimplementasikan via polling (TanStack Query) atau SSE/WebSocket dari backend.

Struktur Env di Kode

  • Akses env melalui modul src/lib/env.ts:
    • Env.API_BASE_URL
    • Env.MIDTRANS_CLIENT_KEY
    • Env.MIDTRANS_ENV

Lisensi

Internal project skeleton.