Documentation
¶
Index ¶
- Variables
- type AcceptOwnershipManagedTokenInput
- type AcceptOwnershipManagedTokenObjects
- type ConfigureMinterObjects
- type DeployAndInitManagedTokenInput
- type DeployManagedTokenObjects
- type DeployManagedTokenOutput
- type ExecuteOwnershipTransferToMcmsManagedTokenInput
- type ExecuteOwnershipTransferToMcmsManagedTokenObjects
- type ManagedTokenBurnInput
- type ManagedTokenConfigureNewMinterInput
- type ManagedTokenDeployInput
- type ManagedTokenDeployOutput
- type ManagedTokenIncrementMintAllowanceInput
- type ManagedTokenInitializeInput
- type ManagedTokenInitializeObjects
- type ManagedTokenMintInput
- type ManagedTokenPauseInput
- type ManagedTokenSetUnlimitedMintAllowancesInput
- type ManagedTokenUnpauseInput
- type NoObjects
- type TransferOwnershipManagedTokenInput
- type TransferOwnershipManagedTokenObjects
Constants ¶
This section is empty.
Variables ¶
View Source
var AcceptOwnershipManagedTokenOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip-managed-token-accept-ownership", "package", "configure"), semver.MustParse("0.1.0"), "Accepts ownership of the ManagedToken", acceptOwnershipManagedTokenHandler, )
View Source
var DeployAndInitManagedTokenSequence = cld_ops.NewSequence( "sui-deploy-managed-token-seq", semver.MustParse("0.1.0"), "Deploys and sets initial managed token configuration", func(env cld_ops.Bundle, deps sui_ops.OpTxDeps, input DeployAndInitManagedTokenInput) (DeployManagedTokenOutput, error) { deployReport, err := cld_ops.ExecuteOperation(env, DeployCCIPManagedTokenOp, deps, input.ManagedTokenDeployInput) if err != nil { return DeployManagedTokenOutput{}, err } initReport, err := cld_ops.ExecuteOperation( env, ManagedTokenInitializeOp, deps, ManagedTokenInitializeInput{ ManagedTokenPackageId: deployReport.Output.PackageId, CoinObjectTypeArg: input.CoinObjectTypeArg, TreasuryCapObjectId: input.TreasuryCapObjectId, DenyCapObjectId: input.DenyCapObjectId, PublisherObjectId: deployReport.Output.Objects.PublisherObjectId, }, ) if err != nil { return DeployManagedTokenOutput{}, err } minterObjectId := "" if input.MinterAddress != "" { minterReport, err := cld_ops.ExecuteOperation( env, ManagedTokenConfigureNewMinterOp, deps, ManagedTokenConfigureNewMinterInput{ ManagedTokenPackageId: deployReport.Output.PackageId, CoinObjectTypeArg: input.CoinObjectTypeArg, StateObjectId: initReport.Output.Objects.StateObjectId, OwnerCapObjectId: initReport.Output.Objects.OwnerCapObjectId, MinterAddress: input.MinterAddress, Allowance: input.Allowance, IsUnlimited: input.IsUnlimited, Source: input.Source, }, ) if err != nil { return DeployManagedTokenOutput{}, err } minterObjectId = minterReport.Output.Objects.MinterCapObjectId } symbol, err := getSymbol(env, deps, input.CoinObjectTypeArg) if err != nil { return DeployManagedTokenOutput{}, fmt.Errorf("failed to get coin symbol: %w", err) } return DeployManagedTokenOutput{ ManagedTokenPackageId: deployReport.Output.PackageId, TokenSymbol: symbol, Objects: DeployManagedTokenObjects{ OwnerCapObjectId: initReport.Output.Objects.OwnerCapObjectId, StateObjectId: initReport.Output.Objects.StateObjectId, PublisherObjectId: deployReport.Output.Objects.PublisherObjectId, MinterCapObjectId: minterObjectId, UpgradeCapObjectId: deployReport.Output.Objects.UpgradeCapObjectId, }, }, nil }, )
View Source
var DeployCCIPManagedTokenOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip-managed-token", "package", "deploy"), semver.MustParse("0.1.0"), "Deploys the CCIP managed token package", deployHandler, )
View Source
var ExecuteOwnershipTransferToMcmsManagedTokenOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "execute_ownership_transfer_to_mcms"), semver.MustParse("0.1.0"), "Executes ownership transfer to MCMS for the CCIP ManagedToken", executeOwnershipTransferToMcmsManagedTokenHandler, )
View Source
var ManagedTokenBurnOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "burn"), semver.MustParse("0.1.0"), "Burns tokens in the CCIP Managed Token contract", burnHandler, )
View Source
var ManagedTokenConfigureNewMinterOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "configure_new_minter"), semver.MustParse("0.1.0"), "Configures a new minter for the CCIP Managed Token contract", configureNewMinterHandler, )
View Source
var ManagedTokenIncrementMintAllowanceOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "increment_mint_allowance"), semver.MustParse("0.1.0"), "Increments mint allowance for the CCIP Managed Token contract", incrementMintAllowanceHandler, )
View Source
var ManagedTokenInitializeOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "initialize"), semver.MustParse("0.1.0"), "Initializes the CCIP Managed Token contract", initManagedTokenHandler, )
View Source
var ManagedTokenMintOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "mint"), semver.MustParse("0.1.0"), "Mints tokens in the CCIP Managed Token contract", mintHandler, )
View Source
var ManagedTokenPauseOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "pause"), semver.MustParse("0.1.0"), "Pauses the CCIP Managed Token contract", pauseHandler, )
View Source
var ManagedTokenSetUnlimitedMintAllowancesOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "set_unlimited_mint_allowances"), semver.MustParse("0.1.0"), "Sets unlimited mint allowances for the CCIP Managed Token contract", setUnlimitedMintAllowancesHandler, )
View Source
var ManagedTokenUnpauseOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip", "managed_token", "unpause"), semver.MustParse("0.1.0"), "Unpauses the CCIP Managed Token contract", unpauseHandler, )
View Source
var TransferOwnershipManagedTokenOp = cld_ops.NewOperation( sui_ops.NewSuiOperationName("ccip-managed-token-transfer-ownership", "package", "configure"), semver.MustParse("0.1.0"), "Transfers ownership of the ManagedToken", transferOwnershipManagedTokenHandler, )
Functions ¶
This section is empty.
Types ¶
type AcceptOwnershipManagedTokenObjects ¶
type AcceptOwnershipManagedTokenObjects struct {
}
type ConfigureMinterObjects ¶
type ConfigureMinterObjects struct {
MinterCapObjectId string
}
type DeployManagedTokenOutput ¶
type DeployManagedTokenOutput struct {
ManagedTokenPackageId string
TokenSymbol string
Objects DeployManagedTokenObjects
}
type ExecuteOwnershipTransferToMcmsManagedTokenObjects ¶
type ExecuteOwnershipTransferToMcmsManagedTokenObjects struct {
}
type ManagedTokenBurnInput ¶
type ManagedTokenBurnInput struct {
ManagedTokenPackageId string
CoinObjectTypeArg string
StateObjectId string
MintCapObjectId string
DenyListObjectId string
CoinObjectId string
FromAddress string
}
MANAGED_TOKEN -- burn
type ManagedTokenDeployInput ¶
type ManagedTokenIncrementMintAllowanceInput ¶
type ManagedTokenIncrementMintAllowanceInput struct {
ManagedTokenPackageId string
CoinObjectTypeArg string
StateObjectId string
OwnerCapObjectId string
MintCapObjectId string
DenyListObjectId string
AllowanceIncrement uint64
}
MANAGED_TOKEN -- increment_mint_allowance
type ManagedTokenInitializeObjects ¶
MANAGED_TOKEN -- INITIALIZE
type ManagedTokenMintInput ¶
type ManagedTokenMintInput struct {
ManagedTokenPackageId string
CoinObjectTypeArg string
StateObjectId string
MintCapObjectId string
DenyListObjectId string
Amount uint64
Recipient string
}
MANAGED_TOKEN -- mint
type ManagedTokenPauseInput ¶
type ManagedTokenPauseInput struct {
ManagedTokenPackageId string
CoinObjectTypeArg string
StateObjectId string
OwnerCapObjectId string
DenyListObjectId string
}
MANAGED_TOKEN -- pause
type ManagedTokenSetUnlimitedMintAllowancesInput ¶
type ManagedTokenSetUnlimitedMintAllowancesInput struct {
ManagedTokenPackageId string
CoinObjectTypeArg string
StateObjectId string
OwnerCapObjectId string
MintCapObjectId string
DenyListObjectId string
IsUnlimited bool
}
MANAGED_TOKEN -- set_unlimited_mint_allowances
type ManagedTokenUnpauseInput ¶
type ManagedTokenUnpauseInput struct {
ManagedTokenPackageId string
CoinObjectTypeArg string
StateObjectId string
OwnerCapObjectId string
DenyListObjectId string
}
MANAGED_TOKEN -- unpause
type TransferOwnershipManagedTokenObjects ¶
type TransferOwnershipManagedTokenObjects struct {
}
Click to show internal directories.
Click to hide internal directories.