Notification Inbox
Flow Summary
The current notification inbox flow is:
Step 1. Load the notification listGET /api/v1/mobile_user/notifications
Step 2. Mark one notification as readPATCH /api/v1/mobile_user/notifications/{id}/read
Step 3. Mark all notifications as readPATCH /api/v1/mobile_user/notifications/read-all
Step 4. Refresh the unread badge countGET /api/v1/mobile_user/notifications/unread-count
All routes below should be treated as protected routes and sent with:
Authorization: Bearer <access_token>
Notification Data Model
These inbox APIs return records from mobile_user_notifications.
Important current fields:
notification_typeuses the same transaction-style enum values used elsewhere in the backend, commonly:CARD_REQUESTTOP_UPWITHDRAWPURCHASEFEEREFUNDTRANSFERRECEIVE
statuscommonly uses:PENDINGSUCCESSFAILED
titleandcontentare translated at response time from the internalnotification_key
Localization behavior
- Send
Accept-Language: zhto get Chinese notification title/content when a translation exists - If a translation key is missing, the handler falls back to the raw
notification_keystring for bothtitleandcontent
1. List Notifications
GET /api/v1/mobile_user/notifications
Returns a paginated list of notifications for the authenticated mobile user.
Query parameters
| Name | Required | Notes |
|---|---|---|
page | No | Default 1 |
limit | No | Default 20, capped at 100 |
is_read | No | true for read, false for unread |
notification_type | No | Filters by the raw stored type |
status | No | Filters by the raw stored status |
Important backend behavior
- The list is scoped to the authenticated mobile user
- Results are always ordered by
created_at DESC - The handler applies localization after loading the rows
Success response shape
{
"status_code": 200,
"message": "Success",
"data": [
{
"id": 81,
"uuid": "0d65f58d-47f6-43d7-84b2-4bdc8d44e391",
"card_id": 508,
"notification_type": "TOP_UP",
"status": "SUCCESS",
"title": "Top up successful",
"content": "Your card top up has completed successfully.",
"source_id": 42,
"is_read": false,
"created_at": "2026-02-28T10:00:00Z",
"updated_at": "2026-02-28T10:00:00Z"
}
],
"metadata": {
"current_page": 1,
"limit": 20,
"total": 1
}
}
2. Mark One Notification As Read
PATCH /api/v1/mobile_user/notifications/{id}/read
Marks one notification as read for the current mobile user.
Notes
idis the local numeric notification row ID- The lookup is scoped to the current mobile user, so another user's notification returns not found
- This is effectively idempotent: if the notification is already read, the handler still returns success and leaves the existing
read_atunchanged
Success response shape
{
"status_code": 200,
"message": "Success",
"data": {
"id": 81,
"is_read": true,
"read_at": "2026-02-28T10:05:00Z"
}
}
3. Mark All Notifications As Read
PATCH /api/v1/mobile_user/notifications/read-all
Marks every unread notification as read for the current mobile user.
Success response shape
{
"status_code": 200,
"message": "Success",
"data": {
"updated_count": 3
}
}
Notes
- Only rows with
read_at IS NULLare updated - If everything is already read, the call still succeeds and returns
updated_count: 0
4. Get Unread Count
GET /api/v1/mobile_user/notifications/unread-count
Returns the current unread notification badge count.
Success response shape
{
"status_code": 200,
"message": "Success",
"data": {
"unread_count": 5
}
}
Integration Notes
- Use the list endpoint for the inbox screen and pass
is_read=falsefor an unread-only tab if needed. - Use
read-allafter a bulk “mark all read” action in the app. - Refresh
unread-countafter read actions to keep the badge in sync.