Skip to content

Implement Transaction History/Activity Endpoint #63

@KuchiMercy

Description

@KuchiMercy

Complexity: Medium (150 points)

Description

Add dedicated endpoint to retrieve escrow activity history with filtering and pagination.

Requirements and Context

EscrowEvent entity logs all escrow actions but lacks dedicated retrieval endpoint
Events are returned nested in escrow response but no standalone query
Users need to audit escrow timeline for transparency and dispute evidence
Required for dashboard activity feeds

Suggested Execution

Fork repo, create branch feat/transaction-history
Create ListEventsDto with filters: eventType, dateRange, actorId
Add findEvents method to EscrowService
Create endpoints:
GET /escrows/:id/events - events for specific escrow
GET /events - all events for user's escrows (with pagination)
Support sorting by timestamp (default: descending)
Include actor details (wallet address) in response

Test and Commit

Test pagination and filtering
Test user can only see events from their escrows
Verify event ordering
Test empty result sets

Example Commit Message

feat: add escrow activity history endpoints with filtering

Expose escrow events via dedicated endpoints supporting pagination,
filtering by event type, and date range queries.

Guidelines

Ensure party-level access control (users see only their escrows' events)
Consider rate limiting for event queries
Format timestamps consistently (ISO 8601)
Support cursor-based pagination for performance (future enhancement)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions