Skip to content

feat: implement wallet transaction history with Stellar Horizon (#63) - #137

Open
tarai-dl wants to merge 1 commit into
sorosave-protocol:mainfrom
tarai-dl:rn/fix-63-stellar-horizon
Open

feat: implement wallet transaction history with Stellar Horizon (#63)#137
tarai-dl wants to merge 1 commit into
sorosave-protocol:mainfrom
tarai-dl:rn/fix-63-stellar-horizon

Conversation

@tarai-dl

Copy link
Copy Markdown

Summary

Implements on-chain transaction history fetching and display using the Stellar Horizon API.

Changes

  • **** — New Horizon API client with:

    • Cursor-based pagination for navigating transaction pages
    • In-memory cache with 30-second TTL to reduce API calls
    • Operation enrichment (fetches operations per transaction)
    • Typed interfaces for transactions, operations, and pages
    • Configurable via NEXT_PUBLIC_HORIZON_URL and NEXT_PUBLIC_CONTRACT_ID env vars
  • **** — New transaction history page with:

    • Loading skeletons while fetching
    • Operation badges (Payment, Contract Invoke, etc.) with color coding
    • Truncated hashes and addresses for readability
    • Previous/Next pagination controls
    • Refresh button with loading animation
    • Empty state handling
    • Error state display
  • **** — Added Transactions navigation link

Acceptance Criteria

  • Query Horizon API for transactions involving the contract
  • Parse operation types (payments, contract invocations)
  • Display in a formatted transaction list
  • Add pagination for large histories
  • Cache results to reduce API calls

Closes #63

…save-protocol#63)

- Add src/lib/horizon.ts: Horizon API client with cursor-based pagination,
  in-memory caching (30s TTL), operation enrichment, and typed interfaces
- Add src/app/transactions/page.tsx: Transaction history page with loading
  skeletons, operation badges, pagination controls, and refresh button
- Update Navbar with Transactions navigation link

Closes sorosave-protocol#63
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement wallet transaction history with Stellar Horizon

1 participant