SnowconeDAO
ResourcesMediaDocs
  • Introduction
  • Create
    • Make Your Snowcone Project
      • Project Details
      • Funding
      • Token
      • Rules
    • Governance Resources
      • Snapshot
      • Gnosis Safe
    • Community Resources
      • Make a Discord Server
  • Learn
    • Overview
    • Architecture
    • Administration
    • Risk
    • Glossary
      • Ballot
      • Data Source
      • Delegate
      • Discount Rate
      • Funding cycle
      • NFT rewards
      • Operator
      • Overflow
      • Payment terminal
      • Project
      • Redemption rate
      • Reserved tokens
      • Split allocator
      • Splits
      • Tokens
    • Tokenomics
  • Build
    • Getting Started
    • Basics
    • Project NFT
    • Programmable treasury
    • Treasury extensions
      • Ballot
      • Data Source
      • Pay delegate
      • Redemption Delegate
      • Split Allocator
    • Utilities
      • Project payer
      • Splits Payer
  • API
    • Data Structures
      • SNOW721PricingParams
      • SNOW721Tier
      • SNOW721TierParams
      • SNOWBitmapWord
      • SNOWDeployTiered721DelegateData
      • SNOWDidPayData
    • Contracts
      • SNWProjects
        • Event
          • Create
          • SetMetadata
          • SetTokenUriResolver
        • Properties
          • Count
          • metadataContentOf
          • tokenUriResolver
        • Read
          • supportsInterface
          • tokenURI
        • Write
          • createFor
          • setMetadataOf
          • setTokenUriResolver
  • Subgraph
    • Subgraph Entities
    • Sample Queries
Powered by GitBook

SnowconeDAO

On this page

Was this helpful?

Export as PDF
  1. Build
  2. Treasury extensions

Ballot

Specifications

A contract can be transformed into a funding cycle ballot by adhering to ISnowconeFundingCycleBallot:

interface ISnowconeFundingCycleBallot {
  function duration() external view returns (uint256);

  function stateOf(
    uint256 _projectId,
    uint256 _configuration,
    uint256 _start
  ) external view returns (SnowconeBallotState);
}

Two functions must be implemented: duration(...) and stateOf(...). The result of duration(...) is the number of seconds the ballot lasts for from the moment the reconfiguration is proposed. During this time, the protocol automatically interprets the ballot's state as SnowconeBallotState.Active. The result of stateOf(...) returns the SnowconeBallotState. If a configuration is approved and the duration has expired, the SnowconeFundingCycleStore will use it as the project's current funding cycle when it becomes active. Otherwise, it will make a copy of the latest approved cycle to use.

When extending the pay functionality with a delegate, the protocol will pass a projectId, a configuration, and a start to the stateOf(...) function. configuration is the identifier of the funding cycle being evaluated, and also the unix timestamp in seconds of when the reconfiguration was proposed. start is the unix timestamp the reconfiguration is scheduled to start at if that reconfiguration is approved.

Once the duration(...) has expired, the returned value of stateOf(...) should no longer change.

Attaching

New ballot contracts should be deployed independently. Once deployed, its address can be configured into a project's funding cycle. The ballot will take effect while that funding cycle is active, and will be used for evaluating subsequent reconfigurations.

Last updated 1 year ago

Was this helpful?