Skip to main content

Notification Endpoints

Notification endpoints allow users to retrieve notifications for their accounts, enabling push notification features in frontend applications.

Get Account Notifications

Retrieves all notifications for a given account address. Endpoint: GET /accounts/{account}/notifications

Path Parameters

  • account (string, required): Ethereum wallet address to retrieve notifications for

Response

Returns an array of notification objects. Typical notification fields:

Code Examples

Response Example

Empty array if no notifications:

Notes

CMS Requirement

The notifications endpoint requires CMS integration:
  • Environment variable CMS_ENABLED must be set to true
  • CMS_API_KEY must be configured

Supported Notification Types

Notification Channels

Users can subscribe to receive notifications via:
  • Telegram Bot: Real-time messages via Telegram
  • Web Push: Browser push notifications
  • Email: Email alerts (if configured)
  • Webhook: Custom webhook integrations

Caching

Notification responses are cached for 5 minutes (300 seconds):

Testing Locally

Sending Test Notifications

Integration with Frontend

Polling Pattern:
With Caching:

Error Handling

Best Practices

  1. Cache locally: Store notifications in frontend state to reduce requests
  2. Respect cache headers: Honor the 5-minute cache period
  3. Handle empty responses: Empty arrays are normal for accounts without notifications
  4. Display timestamps: Show when notifications were created
  5. Group by type: Consider grouping notifications by type in the UI
  6. Mark as read: Implement local read/unread state on the frontend
  7. Pagination: Implement client-side pagination for large notification lists
  8. Error handling: Gracefully handle API errors without breaking the UI
Last modified on March 4, 2026