> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fairground.fi/llms.txt
> Use this file to discover all available pages before exploring further.

# pauseMarket

> Python SDK reference for pauseMarket.

Pause or unpause a market.

```python theme={null}
async def pauseMarket(marketId: int, toPause: bool):
    """Pause or unpause a market."""
    contract = retrieveContract()
    w3 = retrieveWeb3Instance()
    transaction = contract.functions.pauseMarket(marketId, toPause).build_transaction(
        {
            "from": Web3.to_checksum_address(os.getenv("ACCOUNT")),
            "nonce": w3.eth.get_transaction_count(
                Web3.to_checksum_address(os.getenv("ACCOUNT"))
            ),
        }
    )
    await submitTransactionWithOracle(w3, transaction, marketId)

```
