-
Notifications
You must be signed in to change notification settings - Fork 19
Closed
Labels
Stellar WaveIssues in the Stellar wave programIssues in the Stellar wave programgood first issueGood for newcomersGood for newcomerssmart-contract
Description
Description:
Implement a GET /verify/:hash/history endpoint that retrieves the full on-chain history for a document hash — all Stellar transactions that reference the hash in their memo field.
Requirements:
- Extend
StellarClientwithget_hash_history(document_hash: &str) -> Result<Vec<TransactionRecord>>whereTransactionRecordcontains:pub struct TransactionRecord { pub transaction_id: String, pub timestamp: i64, pub memo: String, pub ledger: u64, }
- The Horizon query must paginate through results (
limit=200, follownextcursor links if present) - Sort results chronologically (oldest first)
- Cache the full history with a TTL of 300 seconds
- Return
404if no transactions are found for the hash
Acceptance Criteria:
- Returns an ordered list of all transactions referencing the hash
- Pagination is followed (not just the first page)
- Cache is used on subsequent requests within TTL
- Unit tests for the sorting and pagination logic
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Stellar WaveIssues in the Stellar wave programIssues in the Stellar wave programgood first issueGood for newcomersGood for newcomerssmart-contract