> For the complete documentation index, see [llms.txt](https://unirep.gitbook.io/unirep-social/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://unirep.gitbook.io/unirep-social/cli/epoch-transition.md).

# Epoch Transition

An epoch transition should be called to terminate an epoch

* See (the definition of epoch transition).

### `epochTransition`

```
npx ts-node cli/index.ts epochTransition 
                  [-h] 
                  [-e ETH_PROVIDER] 
                  [-t] 
                  -x CONTRACT 
                  (-dp | -d ETH_PRIVKEY)
```

* Every user can execute epoch transition and it can only be called once.

### Options

```
  -e ETH_PROVIDER, --eth-provider ETH_PROVIDER
                        A connection string to an Ethereum provider. Default: http://localhost:8545
  -t, --is-test         Indicate if the provider is a testing environment
  -x CONTRACT, --contract CONTRACT
                        The Unirep Social contract address
  -dp, --prompt-for-eth-privkey
                        Whether to prompt for the user's Ethereum private key and ignore -d / --eth-privkey
  -d ETH_PRIVKEY, --eth-privkey ETH_PRIVKEY
                        The deployer's Ethereum private key
```

#### Options inherited from parent commands <a href="#options-inherited-from-parent-commands" id="options-inherited-from-parent-commands"></a>

```
  -h, --help            Show this help message and exit.
```
