Skip to main content

Rent Ask

Create or modify the usership rental offer for an existing Ecosystem namespace. Enables / disables the rental listing and sets the daily rent price. Only the Ecosystem owner is permitted to execute this instruction.

open-token ecosystem rent-ask --help

Synopsis

open-token ecosystem rent-ask <Name> <Enabled> <Rent Per Day>

Arguments

ArgumentTypeRequiredDescription
<Name>StringYesTarget Ecosystem namespace name. No dot characters. Must be an existing active on‑chain ecosystem account.
<Enabled>u8YesToggle usership offer status. 0 = false(disable offer), 1 = true(enable offer). When disabled, new rent‑bid requests will be rejected.
<Rent Per Day>u64YesDaily rent amount in base token units. Defines how much a renter pays per calendar‑day of usership. Value takes effect only when <Enabled> is set to 1.

Behaviour

  • Transaction signer must match stored Ecosystem owner public key; returns OwnerMismatch on authorization failure.
  • Validates target Ecosystem exists and is not expired (NameExpired).
  • Persists the rental offer configuration on‑chain: toggle status + per‑day rent price.
  • Setting <Enabled>=0 closes the offer; prevents new rent bids, does NOT terminate an already‑active ongoing usership lease. Existing renter retains usership until lease expiry.
  • Setting <Enabled>=1 opens the offer; allows external users to call rent‑bid to acquire usership.
  • Does not modify ecosystem ownership, meta, body, or ownership expiry timestamp.
  • This only configures the listing; it does not create a rental lease. Actual lease creation happens via rent‑bid.

Constraints & Validation Rules

  1. OwnerMismatch: Transaction signer is not the Ecosystem owner.
  2. NameExpired: Ecosystem ownership registration is expired; cannot configure rent offer.
  3. NameTooLong / NameEmpty: Invalid ecosystem name input.
  4. Invalid <Enabled> value: any value other than 0 or 1 will cause program validation failure.
  5. Zero‑price is allowed by program logic unless treasury enforces a minimum rent price.

Usage Example

Enable usership offer for ecosystem open, set daily rent price to 1000 base units:

open-token ecosystem rent-ask open 1 1000

Disable the usership offer for ecosystem open (existing active lease remains valid):

open-token ecosystem rent-ask open 0 1000