API Reference
Complete endpoint reference for the 747 platform. The platform exposes two API surfaces: the Webapp API on port 3000 and the Agent API on port 3747.
Authentication Methods
Session — Bearer token obtained from /wapi/auth/login. Sent as Authorization: Bearer <token>.
API key — Key pair in pk_:sk_ format. Public key identifies the merchant; secret key authenticates requests via HMAC signature.
Cron secret — Shared secret passed as a query parameter to protect scheduled background tasks.
Gateway — DirectPay webhook callbacks verified by signature.
Webapp API
Port 3000 — serves the tenant-facing web application and merchant integrations.
Authentication
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /wapi/auth/login | Public | Tenant login |
| POST | /wapi/auth/register | Public | Tenant registration |
| POST | /wapi/auth/reset | Public | Password reset |
| POST | /wapi/auth/verify | Public | Email/phone verification |
Requests
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /wapi/requests/create | Public | Submit deposit/withdrawal |
| GET | /wapi/requests/status | Public | Check request status |
| GET | /wapi/requests/list | Session | List tenant's requests |
| POST | /wapi/requests/process | Session | Approve/reject/cancel |
| GET | /wapi/requests/stats | Session | Transaction statistics |
Payments
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /wapi/payment/create | Rate-limited | Create NexusPay payin |
| POST | /wapi/payment/finalize | Public | Verify & complete payment |
| POST | /wapi/payment/webhook | Gateway | DirectPay callback |
| GET | /wapi/payment/checkout | Public | Proxy redirect to gateway |
| POST | /wapi/payment/retry | Cron secret | Retry failed transfers |
Proxy
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /wapi/proxy | Session | Single-bridge 747 API call |
| POST | /wapi/proxy/multi | Session | Multi-bridge parallel call |
NexusPay
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| GET | /wapi/nexuspay/me | Session | Tenant NexusPay status |
| POST | /wapi/nexuspay/activate-payment | Session | Pay activation fee |
Merchant API
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /api/v1/payments | API key | Create payment |
| GET | /api/v1/payments | API key | Check status (query) |
| GET | /api/v1/payments/:id | API key | Check status (path) |
Background Tasks
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| GET | /wapi/cron?task=auto-cancel | Cron secret | Cancel stale payments |
| GET | /wapi/cron?task=retry-transfers | Cron secret | Retry failed transfers |
| GET | /wapi/cron?task=panel-sync | Cron secret | Sync panel transactions |
Agent API
Port 3747 — proxies requests to the Agent Ledger panel. All endpoints accept POST and return JSON.
| Method | Endpoint | Description |
|---|---|---|
| POST | /auth/login | 747 panel authentication |
| POST | /balance | Agent balance query |
| POST | /transfer | Player deposit/withdrawal |
| POST | /agent/deposit | Agent-to-agent deposit |
| POST | /agent/withdraw | Agent-to-agent withdrawal |
| POST | /transactions | Transaction history |
| POST | /players | Player list |
| POST | /players/count | Player count |
| POST | /agent/direct-children | Downline agents |
| POST | /agents/count | Agent count |
| POST | /commission/assign | Assign commission plan |
| POST | /commission/assignable-plans | List available plans |
Base URLs
# Webapp API
https://agentledgerhub.com
# Agent API
http://localhost:3747
The Agent API is not publicly exposed. All agent operations are proxied through the Webapp API via the /wapi/proxy endpoints.