Andromeda
ADO LibraryBuild AppsDevelop ADOsCLIWeb Application Docs
Andromeda
Andromeda
  • Platform and Framework
    • Introduction to AndromedaOS
    • ADO Classes
    • Andromeda Messaging Protocol
      • Kernel
      • ADO Database
      • Economics Engine
      • Virtual File System
    • ADO Base
      • AndromedaMsg
      • AndromedaQuery
    • Common Types
    • Deployed Contracts
    • ADO Versions
  • Andromeda Digital Objects
    • Introduction to ADOs
    • Address List
    • Auction
    • App
    • Curve
    • CW20
    • CW20 Staking
    • CW721
    • CW20 Exchange
    • Fixed Amount Splitter
    • Graph
    • Lockdrop
    • Marketplace
    • Merkle-Airdrop
    • Point
    • Primitive
    • Rates
    • Splitter
    • Timelock
    • Validator Staking
    • Vesting
  • Andromeda Apps
    • Introduction to Apps
    • Auctioning App
    • Cw20 Staking App
    • Marketplace App
  • Developing an ADO
    • Getting Started
      • Instantiation
      • Execution
      • Queries
      • Testing
    • Error Handling and Migrate Function
    • CW3 EXAMPLE
      • InstantiateMsg
      • ExecuteMsg
      • QueryMsg
      • Testing
    • ADO Submissions
  • Andromeda CLI
    • Introduction
    • Help and Shortcuts
    • ADO
    • Bank
    • Chain
    • Env
    • Gql
    • Tx
    • OS
    • Wallet
    • Wasm
    • Clearing CLI Data
    • Clear and Exit
  • Chain
    • Running a Node
    • Staking and Rewards
  • Andromeda Dashboard
    • Tokenomics Dashboard
    • Dashboard API
  • Andromeda Changelog
    • Newest Releases
  • Additional Resources
    • GitHub
    • Website
    • White Paper
Powered by GitBook

Additional Resources

  • Github
  • Website

Community

  • Discord
  • Telegram

Socials

  • Twitter
  • Medium
  • Youtube
On this page
  • InstantiateMsg
  • ExecuteMsg
  • AddActorPermission
  • RemoveActorPermission
  • Base Executes
  • QueryMsg
  • IncludesActor
  • ActorPermission
  • Base Queries

Was this helpful?

  1. Andromeda Digital Objects

Address List

PreviousIntroduction to ADOsNextAuction

Last updated 3 months ago

Was this helpful?

The address list ADO is a smart contract that facilitates setting up for ADOs. Instead of setting up the permission on the ADO itself, the owner can reference this ADO instead.

Permissioning allows ADO owners to give/restrict access to addresses to execute messages on their ADOs.

ADO_type: address-list

Version: 2.1.0

InstantiateMsg

pub struct InstantiateMsg {
    pub actor_permission: Option<ActorPermission>,
    pub kernel_address: String,
    pub owner: Option<String>
}
{
"actor_permission":{
    "actor":"andr1...",
    "permission":{
        "whitelisted":null
        }
    },
"kernel_address":"andr1..."
}
Name
Type
Description

actor_permission

Optional permission to set at instantiation.

kernel_address

String

Contract address of the kernel contract to be used for AMP messaging. Kernel contract address can be found in our deployed contracts.

owner

Option<String>

Optional address to specify as the owner of the ADO being created. Defaults to the sender if not specified.

ActionPermission

pub struct ActorPermission {
    pub actor: Addr,
    pub permission: Permission,
}
Name
Type
Description

actor

Addr

The address to apply the permission on.

permission

The type of permission to assign to the actor.

Permission

An enum to represent a user's permission for an action:

Expiration defaults to Never if not provided.

pub enum Permission {
    Blacklisted(Option<Expiry>),
    Limited {
        expiration: Option<Expiry>,
        uses: u32,
    },
    Whitelisted(Option<Expiry>),
}
  • Blacklisted: The user cannot perform the action until after the provided expiration.

  • Limited: The user can perform the action while uses are remaining and before the provided expiration.

  • Whitelisted: The user can perform the action until the provided expiration.

ExecuteMsg

AddActorPermission

Only available to the ADO owner.

Add permissioning to the specified list of actors (Addresses).

pub enum ExecuteMsg {
PermissionActors {
        actors: Vec<AndrAddr>,
        permission: LocalPermission,
    },
 }
{
"actor_permission":{
    "actors":["andr1...","andr1...",...],
    "permission":{
        "blacklisted":null
        }
    }
}
Name
Type
Description

actors

The list of addresses to apply the permission to.

permission

The type of permission to assign to the actor.

RemoveActorPermission

Only available to the ADO owner.

Removes previously set permission on the specified actors.

pub enum ExecuteMsg {
  RemovePermissions {
        actors: Vec<AndrAddr>
    },
}
{
"remove_actor_permission":{
    "actors":"andr1..."
    }
}
Name
Type
Description

actors

The address to remove permissions from.

Base Executes

QueryMsg

IncludesActor

Checks if the specified actor has any permissions applied.

pub enum QueryMsg {
    #[returns(IncludesActorResponse)]
    IncludesActor { actor: Addr },
    }
{
"includes_actor":{
    "actor":"andr1..."
    }
}
Name
Type
Description

actor

Addr

The address to check permissions for.

Returns true if the address has any permissions and false otherwise.

ActorPermission

Queries the permission applied on the specified actor.

pub enum QueryMsg {
   #[returns(ActorPermissionResponse)]
    ActorPermission { actor: Addr },
    }
{
"actor_permission":{
    "actor":"andr1..."
    }
}
Name
Type
Description

actor

Addr

The address to get permissions for.

Base Queries

Option<>

Vec<>

Vec<>

The rest of the execute messages can be found in the section.

Returns a struct with the type of permission.

The rest of the query messages can be found in the section.

ADO Base
ADO Base
Permission
ActionPermission
Permission
Permission
permissions
AndrAddr
AndrAddr