��# Issue 12: Add Ballot Creation Timestamp Verification
Problem
No way to verify when a ballot was created. Timestamp not stored or queryable.
Solution
- Store
created_at: u64 using env.ledger().timestamp() in record_ballot
- Add to
BallotMetadata struct
- Implement
get_ballot_created_at() read function
- TypeScript helper to query creation time for verification
Implementation Tasks
Note for Contributors
Complete Issue #1 (ballot metadata storage) first. The created_at timestamp is set once during record_ballot and is immutable thereafter. Use env.ledger().timestamp() to capture the ledger timestamp at ballot creation. Store this value in BallotMetadata and never allow modification. Timestamps enable external verification of ballot creation order and timing. Consider that Stellar block times are approximately 5-6 seconds, so timestamps may have that granularity. Include created_at in all audit reports and use it for queries in combination with expiration checks (Issue #10).
��# Issue 12: Add Ballot Creation Timestamp Verification
Problem
No way to verify when a ballot was created. Timestamp not stored or queryable.
Solution
created_at: u64usingenv.ledger().timestamp()inrecord_ballotBallotMetadatastructget_ballot_created_at()read functionImplementation Tasks
record_ballotinitializationget_ballot_created_at()gettersorobanGetBallotCreatedAt()Note for Contributors
Complete Issue #1 (ballot metadata storage) first. The created_at timestamp is set once during
record_ballotand is immutable thereafter. Useenv.ledger().timestamp()to capture the ledger timestamp at ballot creation. Store this value in BallotMetadata and never allow modification. Timestamps enable external verification of ballot creation order and timing. Consider that Stellar block times are approximately 5-6 seconds, so timestamps may have that granularity. Include created_at in all audit reports and use it for queries in combination with expiration checks (Issue #10).