Skip to main content

GET /polls//tally

Returns the finalized tally for a closed poll, including the managed tally signature and public key for independent verification. Response
{
  "poll_id": "referendum-2026-1",
  "voting_method": "yes_no",
  "counts": {
    "yes": 1203,
    "no": 644
  },
  "total_votes": 1847,
  "confirmed_count": 1731,
  "vote_merkle_root": "<base64>",
  "voter_merkle_root": "<base64>",
  "signature": "<base64-der-encoded-ecdsa-sig>",
  "public_key": "<base64-der-encoded-ecdsa-pubkey>",
  "finalized_at": 1700086400,
  "height": 5891
}

Interpreting confirmed_count

confirmed_count is the number of voters who submitted a TxTypeConfirmReceipt after poll close, acknowledging that their identity_hash appears in the voter registry. total_votes - confirmed_count is the Sybil-audit gap — the number of participants who did not confirm their receipt. This gap is observable but not definitively interpretable without additional context (some non-response is expected from real voters).

Verifying the signature independently

Use the verify package or the standalone CLI:
go run ./verify/cmd/verify --api https://your-deployment.example --poll referendum-2026-1
Or verify programmatically:
payload := verify.BuildSigningPayload(
    tally.VoteMerkleRoot,
    tally.VoterMerkleRoot,
    tally.TotalVotes,
    tally.Counts,
)
ok, err := verify.VerifyECDSA(tally.PublicKey, tally.Signature, payload)
What a valid signature proves:
  • Counts, total votes, and Merkle roots were not modified after poll close
  • The managed signer registered for this deployment produced the signature
  • The Merkle roots commit to the exact List 1 ballot IDs and List 2 identity hashes at close
Errors
CodeMeaning
5Poll not found or not yet closed