# DAO Traits

{% hint style="info" %}
Purpose: Interface definitions for DAO system contracts. Defines traits for upgradable contracts and proposal scripts.
{% endhint %}

## Traits Defined

### upgradable

Interface for upgradable contracts. Used by dao-executor.

Functions:

{% code title="upgradable trait" %}

```
get-impl : () -> (response (optional principal) uint)
  - Get current implementation

set-impl : (principal) -> (response bool uint)
  - Set new implementation

init : (principal) -> (response bool uint)
  - Initialize with implementation
```

{% endcode %}

***

### proposal-script

Interface for DAO proposal contracts. All proposals must implement this trait.

Functions:

{% code title="proposal-script trait" %}

```
execute : () -> (response bool uint)
  - Execute proposal logic
```

{% endcode %}

## Usage

Contracts implementing these traits can interact with the DAO system:

* upgradable: Implemented by dao-executor for implementation management
* proposal-script: Implemented by all proposal contracts for execution by dao-executor


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.zestprotocol.com/start/stacks-market-v2-smart-contracts-overview/v2-contracts/dao-contracts/dao-traits.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
