Creates a commitment to buy a second-level domain without disclosing the actual name. This is implemented according to our commit&reveal scheme.
Entrypoint: commit
Parameter Type | Description |
| SHA-512 hash of a packed tuple of label, owner, and a random nonce corresponding to the intended buy (see TLDRegistrar.Buy). The hashed tuple is of the Michelson type |
type commit_param = bytes| Commit of bytes
parameter (or(bytes %commit)# ... more entrypoints outside of this interoperability spec);
Error | Description |
TLD_REGISTRAR_DISABLED | This TLD registrar is disabled in its config. |
AMOUNT_NOT_ZERO | The transferred amount of tez is not zero. |
Buys a second-level domain based on previous commitment (see TLDRegistrar.Commit).
Entrypoint: buy
Parameter | Type | Description |
label |
| The UTF-8 encoded label of the second-level domain to buy. |
duration |
| Ownership duration represented in days. |
owner |
| The new owner of the given domain. |
address |
| The optional address the given domain resolves to. |
data |
| A map of any additional data clients wish to store with the given domain. |
nonce |
| The chosen commitment nonce. |
type buy_param = {label: bytes;duration: nat;owner: address;address: address option;data: (string, bytes) map;nonce: nat;}| Buy of buy_param michelson_pair_left_comb
parameter (or(pair %buy (bytes %label)(pair (nat %duration)(pair (address %owner)(pair (option %address address)(pair (map %data string bytes) (nat %nonce))))))# ... more entrypoints outside of this interoperability spec);
Error | Description |
TLD_REGISTRAR_DISABLED | This TLD registrar is disabled in its config. |
COMMITMENT_DOES_NOT_EXIST | Corresponding commitment (see TLDRegistrar.Commit) was not created before. |
COMMITMENT_TOO_OLD | The commitment is too old (older than configured age). Try recreating it again. |
COMMITMENT_TOO_RECENT | The commitment is too recent (younger than configured age). Wait for some time. |
LABEL_NOT_AVAILABLE | The requested label already exists and it is not expired. |
INVALID_LABEL | The given label is not valid. See Label Validation. |
DURATION_TOO_LOW | The requested duration is too low (lower than the configured minimum). |
AMOUNT_TOO_LOW | The transferred amount is lower than the actual price. |
AMOUNT_TOO_HIGH | The transferred amount is higher than the actual price. |
Renews second-level domain for requested duration.
Entrypoint: renew
Parameter | Type | Description |
label |
| The UTF-8 encoded label of the second-level domain to buy. |
duration |
| The renewal duration represented in days. |
type renew_param = {label: bytes;duration: nat;}| Renew of renew_param michelson_pair_left_comb
parameter (or(pair %renew(bytes %label)(nat %duration))# ... more entrypoints outside of this interoperability spec);
Error | Description |
TLD_REGISTRAR_DISABLED | This TLD registrar is disabled in its config. |
LABEL_NOT_FOUND | The requested label does not exist. |
LABEL_EXPIRED | The requested label exists but it is expired. Therefore it can be bought, not renewed. |
DURATION_TOO_LOW | The specified duration is too low (lower than the configured minimum). |
AMOUNT_TOO_LOW | The transferred amount is lower than the actual price. |
AMOUNT_TOO_HIGH | The transferred amount is higher than the actual price. |