CPG-CRM FSD Transaction
FSD — Admin CRM
A. Document controlA. Kiểm soát tài liệu
| Doc ID | CPG-FSD-CPG-CRM_FSD_Transaction |
|---|---|
| VersionPhiên bản | 1.0 |
| StatusTrạng thái | Draft |
| Owner | CPG BA / Architecture |
| AudienceĐối tượng | Frontend, Backend, FlyPay Support, QA, Product |
| ClassificationPhân loại | Internal |
| Effective dateNgày hiệu lực | 01/12/2026 |
| Related docs | Admin CRM Index · BR/NFR Catalog |
B. Version historyB. Lịch sử phiên bản
| Version | Date | Author | ChangesThay đổi |
|---|---|---|---|
| 1.0 | 01/12/2026 | Khoa Trinh | Version 1.0 |
C. Table of contentsC. Mục lục
- 1. Module Scope
- 2. User Roles
- 3. Functional Requirements
- 3.1 Features
- 3.1.1 Payment Transactions Listing
- 3.1.2 Payment Transactions Filtering & Search
- 3.1.3 Refund Transactions Listing
- 3.1.4 Refund Transactions Filtering
- 3.1.5 Transaction Details View
- 3.1.6 KYT & Compliance Indicators
- 3.1.7 Pagination & Performance
- 3.2 Use Cases / User Stories
- 4. User Interface
- 4.1 Crypto Transactions Main Screen
- 4.2 Payment Transactions Tab
- 4.3 Refund Transactions Tab
- 4.4 Transaction Details Modal
- 5. Data Requirements
- 5.1 Data Dictionary
- 5.2 Data Models
- 6. API Routes
D. ContentD. Nội dung
1. Module Scope
The Transactions Management Module provides centralized visibility and control over all crypto payment and refund transactions processed by the platform.
The module enables administrators and compliance teams to:
- Search and monitor crypto payment transactions
- Track refund transactions and their linkage to original payments
- Review transaction status, KYT risk, and compliance flags
- Inspect detailed on-chain transaction information
- Support operational, compliance, and audit workflows
This module is read-only by default, with enforcement actions handled by Risk & Compliance modules.
2. User Roles
Role | Description |
|---|---|
System Administrator | Full access to all transaction data |
Compliance Officer | Reviews KYT risk and compliance status |
Finance Manager | Reviews settlement, refunds, and outcomes |
Merchant Support | Investigates merchant transaction issues |
Auditor (Read-only) | Views transactions for audit purposes |
System | Provides KYT risk scoring and compliance flags |
3. Functional Requirements
3.1 Features
3.1.1 Payment Transactions Listing
- Display a list of all crypto payment transactions
- Each row shows:
- Transaction Hash (with copy & explorer link)
- Order ID
- Merchant name
- Amount & asset
- KYT Risk Level
- Compliance Status
- Transaction Status
- Timestamp
- Supports pagination
3.1.2 Payment Transactions Filtering & Search
Filters available:
- Transaction Hash
- Order ID
- Merchant (search by name)
- Date range (From – To)
- Transaction Status
- KYT Risk Level
- Compliance Status
Search results update on user action (Search button).
3.1.3 Refund Transactions Listing
- Separate tab for Refund Transactions
- Each row shows:
- Refund Transaction Hash
- Original Transaction Hash
- Order ID
- Merchant
- Refund Amount & asset
- Transaction Status
- Maker (operator)
- Timestamp
- Supports pagination
3.1.4 Refund Transactions Filtering
Filters available:
- Transaction Hash
- Order ID
- Merchant
- Date range
- Transaction Status
3.1.5 Transaction Details View
- Opened as a modal from both payment and refund lists
- Displays full transaction metadata:
- Order ID
- Transaction Hash
- Merchant
- Payee email
- Amount and asset
- Blockchain network
- Timestamp
- From Address
- To Address
- Transaction Status
- KYT Risk Level
- Compliance Status
- Read-only
- Explorer and copy-to-clipboard supported
3.1.6 KYT & Compliance Indicators
- KYT Risk Levels displayed:
- Low
- Medium
- High
- Compliance Status displayed:
- None
- Pending Review
- Flagged
- These values are derived from external/internal risk engines
3.1.7 Pagination & Performance
- Paginated lists for both tabs
- Page size configurable
- Efficient loading for large datasets
3.2 Use Cases / User Stories
Detailed use-case catalog for this module is maintained under 08_UC:Catalog use case chi tiết của module này được quản lý tại 08_UC:
4. User Interface
4.1 Crypto Transactions Main Screen
- Page title: Crypto Transactions
- Tabs:
- Payment Transactions (default)
- Refund Transactions
- Filter panel at top
- Data table below
- Pagination controls at bottom
4.2 Payment Transactions Tab

Columns:
- Transaction ID
- Transaction Hash (on-chain)
- Order ID
- Invoice Number
- Merchant Name
- Account (Crypto Account ID)
- Blockchain
- Amount + Currency
- KYT Risk Level
- Compliance Status
- Transaction Status
- Webhook Delivery Status
- Created At
Visual elements:
- Risk and status badges
- Clickable hashes and order IDs
4.3 Refund Transactions Tab

Columns:
- Refund Transaction ID
- Refund Transaction Hash
- Original Transaction Hash
- Order ID
- Invoice Number
- Merchant
- Account
- Blockchain
- Refund Amount + Currency
- Refund Status
- Webhook Status
- Created At
4.4 Transaction Details Modal

- Modal title: Transaction Details
- Two-column layout
- Sections:
- Transaction identifiers
- Financial details
- Blockchain details
- Risk & compliance indicators
- Close button only (read-only)
5. Data Requirements
5.1 Data Dictionary
transactions
Field | Type | Description |
|---|---|---|
transaction_id | UUID | Internal transaction identifier |
transaction_hash | String | Blockchain transaction hash |
original_transaction_hash | String | Reference for refunds |
order_id | String | Merchant order identifier |
invoice_number | VARCHAR(100) | VARCHAR(100) |
service_id | uuid | Payment service reference |
merchant_id | UUID | Merchant identifier |
merchant_name | String | Merchant display name |
amount | Decimal | Transaction amount |
asset | Enum | Crypto asset (USDT, USDC) |
blockchain | Enum | Blockchain network |
from_address | String | Source wallet address |
to_address | String | Destination wallet address |
payee_email | String | Customer email |
txn_status | Enum | Blockchain transaction status |
risk_status | Enum | KYT risk level |
compliance_status | Enum | Compliance review status |
refundable_amount | decimal | Remaining refundable balance |
maker | String | Operator initiating refund |
webhook_status | ENUM | pending, delivered, failed |
block_number | BIGINT | Blockchain block number |
confirmations | INT | Number of confirmations |
created_at | TIMESTAMP | Created time |
updated_at | TIMESTAMP | Last update |
Field | Type | Description |
|---|---|---|
id | UUID | Refund transaction ID |
refund_code | VARCHAR(50) | Refund reference |
original_transaction_id | UUID | FK → transactions.id |
refund_hash | VARCHAR(255) | Refund tx hash |
merchant_id | UUID | Related merchant |
account_id | UUID | Refund source account |
blockchain | VARCHAR(50) | Blockchain |
amount | DECIMAL(18,8) | Refund amount |
currency | VARCHAR(20) | Token |
refund_status | ENUM | pending, success, failed, cancelled |
webhook_status | ENUM | pending, delivered, failed |
created_at | TIMESTAMP | Created time |
updated_at | TIMESTAMP | Updated time |
Field | Type | Description |
|---|---|---|
id | UUID | Webhook log ID |
transaction_id | UUID | Related transaction |
event_type | VARCHAR(100) | payment.success, payment.failed |
endpoint_url | TEXT | Webhook URL |
payload | JSONB | Sent payload |
delivery_status | ENUM | delivered, pending, failed |
retry_count | INT | Number of retries |
last_attempt_at | TIMESTAMP | Last attempt |
created_at | TIMESTAMP | Created time |
5.2 Data Models
- Merchant
- Transaction
- Service
- RefundTransaction
- ComplianceAssessment
- KYTRiskResult
- Merchant 1 -> N Transactions
- Transaction 1 -> 0..1 RefundTransaction
- Transaction 1 -> 1 Service
- Transaction 1 -> 1 KYTRiskResult
- Transaction 1 -> 0..1 ComplianceAssessment
TransactionStatus
- Pending
- Success
- Synced
- Failed
RiskLevel
- Low
- Medium
- High
- Critical
ComplianceStatus
See CPG-CRM/FSD_Compliance, 5.2 Data Models
Webhook Status
- pending
- delivered
- failed
Blockchain
- BSC
- Ethereum
- Polygon
- Tron
Asset
- USDT
- USDC
6. API Routes
Base path suggestion: /api/v1
Method | Route | Purpose | Notes |
|---|---|---|---|
GET | /transactions/payments | List payment transactions | Filters & pagination |
GET | /transactions/refunds | List refund transactions | Filters & pagination |
GET | /transactions/{id} | Get transaction details | Used by detail modal |
GET | /transactions/by-hash/{hash} | Get transaction by hash | Quick lookup |
GET | /transactions/by-order/{orderId} | Get transactions by order | Support use |
GET | /transactions/export | Export transactions | CSV / report use |