# set\_auction\_duration

An entrypoint that setups default auction duration. The duration for previously created auctions will not change. The changes will only affect auctions that will be created after the change of the duration.

### Call parameters

<table><thead><tr><th>Field</th><th width="198.33333333333331">Type</th><th>Description</th></tr></thead><tbody><tr><td>auction_duration</td><td>nat</td><td>New default duration of an auction</td></tr></tbody></table>

### Usage

{% tabs %}
{% tab title="🌮 Taquito" %}

```javascript
const auctionAddress = "KT1...";
const auctionDuration = 86400; // 24 hours
const auction = await tezos.contract.at(auctionAddress);
const operation = await auction.methods.set_auction_duration(auctionDuration).send();

await operation.confirmation();
```

{% endtab %}
{% endtabs %}

### Errors

* `311` - wrong auction duration (less than or equal to 0).
* `400` - `sender` of the transaction is not current administrator.
* `412` - non payable entrypoint (can't accept TEZ tokens during call of an entrypoint).
