Documentation
¶
Index ¶
- func DecodeCustomError(errStr string) string
- func LoadContracts(l *zerolog.Logger, client *seth.Client) error
- func NewEthClientFromEnv(v *viper.Viper, l *zerolog.Logger, ethUrl string) (*seth.Client, error)
- func NewSethClient(configFile string, rpc string, privateKeys []string, chainId uint64) (*seth.Client, error)
- func NewSethClientWithSimulated(configFile string, rpc string, privateKeys []string, chainId uint64, ...) (*seth.Client, error)
- type Factory
- type LedgerConfig
- type RawTx
- type RegisterWorkflowV2Parameters
- type TxClient
- type TxClientConfig
- type TxOutput
- type TxType
- type WorkflowRegistryV2Client
- func (wrc *WorkflowRegistryV2Client) ActivateWorkflow(workflowID [32]byte, donFamily string) (*TxOutput, error)
- func (wrc *WorkflowRegistryV2Client) AllowlistRequest(requestDigest [32]byte, duration time.Duration) error
- func (wrc *WorkflowRegistryV2Client) BatchPauseWorkflows(workflowIDs [][32]byte) (*TxOutput, error)
- func (wrc *WorkflowRegistryV2Client) CanLinkOwner(owner common.Address, validityTimestamp *big.Int, proof [32]byte, ...) error
- func (wrc *WorkflowRegistryV2Client) CanUnlinkOwner(owner common.Address, validityTimestamp *big.Int, signature []byte) error
- func (wrc *WorkflowRegistryV2Client) DeleteWorkflow(workflowID [32]byte) (*TxOutput, error)
- func (wrc *WorkflowRegistryV2Client) GetLinkedOwners(start, batchSize *big.Int) ([]common.Address, error)
- func (wrc *WorkflowRegistryV2Client) GetMaxWorkflowsPerDON(donFamily [32]byte) (uint32, error)
- func (wrc *WorkflowRegistryV2Client) GetMaxWorkflowsPerUserDON(user common.Address, donFamily [32]byte) (uint32, error)
- func (wrc *WorkflowRegistryV2Client) GetWorkflow(owner common.Address, workflowName, tag string) (workflow_registry_v2_wrapper.WorkflowRegistryWorkflowMetadataView, error)
- func (wrc *WorkflowRegistryV2Client) GetWorkflowListByOwnerAndName(owner common.Address, workflowName string, start, limit *big.Int) ([]workflow_registry_v2_wrapper.WorkflowRegistryWorkflowMetadataView, error)
- func (wrc *WorkflowRegistryV2Client) IsAllowedSigner(signer common.Address) (bool, error)
- func (wrc *WorkflowRegistryV2Client) IsOwnerLinked(owner common.Address) (bool, error)
- func (wrc *WorkflowRegistryV2Client) IsRequestAllowlisted(owner common.Address, digest [32]byte) (bool, error)
- func (wrc *WorkflowRegistryV2Client) LinkOwner(validityTimestamp *big.Int, proof [32]byte, signature []byte) (*TxOutput, error)
- func (wrc *WorkflowRegistryV2Client) SetDONOverride(donFamily [32]byte, limit uint32, enabled bool) error
- func (wrc *WorkflowRegistryV2Client) SetDefaults(maxPerDON, maxPerUserDON uint32) error
- func (wrc *WorkflowRegistryV2Client) SetDonLimit(donFamily string, limit uint32, userDefaultLimit uint32) error
- func (wrc *WorkflowRegistryV2Client) SetUserDONOverride(user common.Address, donFamily [32]byte, limit uint32, enabled bool) error
- func (wrc *WorkflowRegistryV2Client) TotalLinkedOwners() (*big.Int, error)
- func (wrc *WorkflowRegistryV2Client) TypeAndVersion() (string, error)
- func (wrc *WorkflowRegistryV2Client) UnlinkOwner(owner common.Address, validityTimestamp *big.Int, signature []byte) (*TxOutput, error)
- func (wrc *WorkflowRegistryV2Client) UpdateAllowedSigners(signers []common.Address, allowed bool) error
- func (wrc *WorkflowRegistryV2Client) UpsertWorkflow(params RegisterWorkflowV2Parameters) (*TxOutput, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeCustomError ¶
func NewEthClientFromEnv ¶
func NewSethClient ¶
Types ¶
type Factory ¶
type Factory interface {
NewWorkflowRegistryV2Client() (*WorkflowRegistryV2Client, error)
GetTxType() TxType
GetSkipConfirmation() bool
}
type LedgerConfig ¶
type RegisterWorkflowV2Parameters ¶
type RegisterWorkflowV2Parameters struct {
WorkflowName string // required: user specified human readable workflow name label
Tag string // required: User input tag for the workflow, e.g. "Por Workflow v2"
WorkflowID [32]byte // required: generated based on the workflow content and owner address
Status uint8 // required
DonFamily string // required: DON family label
BinaryURL string // required: URL location for the workflow binary WASM file
ConfigURL string // optional: URL location for the workflow configuration file (default empty string)
Attributes []byte // optional: 1 to pause workflow after registration, 0 to activate it (default is 0)
KeepAlive bool // optional: whether to keep the other workflows of the same name and owner active after the new deploy (default is false)
}
type TxClientConfig ¶
type TxClientConfig struct {
TxType TxType
LedgerConfig *LedgerConfig
SkipPrompt bool
}
type WorkflowRegistryV2Client ¶
type WorkflowRegistryV2Client struct {
TxClient
ContractAddress common.Address
Wr workflowRegistryV2Contract
}
func NewWorkflowRegistryV2Client ¶
func NewWorkflowRegistryV2Client(logger *zerolog.Logger, ethClient *seth.Client, address string, txcConfig TxClientConfig) *WorkflowRegistryV2Client
func (*WorkflowRegistryV2Client) ActivateWorkflow ¶
func (wrc *WorkflowRegistryV2Client) ActivateWorkflow(workflowID [32]byte, donFamily string) (*TxOutput, error)
func (*WorkflowRegistryV2Client) AllowlistRequest ¶
func (wrc *WorkflowRegistryV2Client) AllowlistRequest(requestDigest [32]byte, duration time.Duration) error
AllowlistRequest sends the request digest to the WorkflowRegistry allowlist with a default expiry of now + 10 minutes. `requestDigestHex` should be the hex string produced by utils.CalculateRequestDigest(...), with or without "0x".
func (*WorkflowRegistryV2Client) BatchPauseWorkflows ¶
func (wrc *WorkflowRegistryV2Client) BatchPauseWorkflows(workflowIDs [][32]byte) (*TxOutput, error)
func (*WorkflowRegistryV2Client) CanLinkOwner ¶
func (*WorkflowRegistryV2Client) CanUnlinkOwner ¶
func (*WorkflowRegistryV2Client) DeleteWorkflow ¶
func (wrc *WorkflowRegistryV2Client) DeleteWorkflow(workflowID [32]byte) (*TxOutput, error)
func (*WorkflowRegistryV2Client) GetLinkedOwners ¶
func (*WorkflowRegistryV2Client) GetMaxWorkflowsPerDON ¶
func (wrc *WorkflowRegistryV2Client) GetMaxWorkflowsPerDON(donFamily [32]byte) (uint32, error)
func (*WorkflowRegistryV2Client) GetMaxWorkflowsPerUserDON ¶
func (*WorkflowRegistryV2Client) GetWorkflow ¶
func (wrc *WorkflowRegistryV2Client) GetWorkflow(owner common.Address, workflowName, tag string) (workflow_registry_v2_wrapper.WorkflowRegistryWorkflowMetadataView, error)
func (*WorkflowRegistryV2Client) GetWorkflowListByOwnerAndName ¶
func (wrc *WorkflowRegistryV2Client) GetWorkflowListByOwnerAndName(owner common.Address, workflowName string, start, limit *big.Int) ([]workflow_registry_v2_wrapper.WorkflowRegistryWorkflowMetadataView, error)
func (*WorkflowRegistryV2Client) IsAllowedSigner ¶
func (wrc *WorkflowRegistryV2Client) IsAllowedSigner(signer common.Address) (bool, error)
func (*WorkflowRegistryV2Client) IsOwnerLinked ¶
func (wrc *WorkflowRegistryV2Client) IsOwnerLinked(owner common.Address) (bool, error)
func (*WorkflowRegistryV2Client) IsRequestAllowlisted ¶
func (wrc *WorkflowRegistryV2Client) IsRequestAllowlisted(owner common.Address, digest [32]byte) (bool, error)
IsRequestAllowlisted queries the registry to check if a given (owner, requestDigest) is allowlisted. requestDigestHex may include or omit the 0x prefix.
func (*WorkflowRegistryV2Client) SetDONOverride ¶
func (wrc *WorkflowRegistryV2Client) SetDONOverride(donFamily [32]byte, limit uint32, enabled bool) error
func (*WorkflowRegistryV2Client) SetDefaults ¶
func (wrc *WorkflowRegistryV2Client) SetDefaults(maxPerDON, maxPerUserDON uint32) error
func (*WorkflowRegistryV2Client) SetDonLimit ¶
func (wrc *WorkflowRegistryV2Client) SetDonLimit(donFamily string, limit uint32, userDefaultLimit uint32) error
func (*WorkflowRegistryV2Client) SetUserDONOverride ¶
func (*WorkflowRegistryV2Client) TotalLinkedOwners ¶
func (wrc *WorkflowRegistryV2Client) TotalLinkedOwners() (*big.Int, error)
func (*WorkflowRegistryV2Client) TypeAndVersion ¶
func (wrc *WorkflowRegistryV2Client) TypeAndVersion() (string, error)
func (*WorkflowRegistryV2Client) UnlinkOwner ¶
func (*WorkflowRegistryV2Client) UpdateAllowedSigners ¶
func (wrc *WorkflowRegistryV2Client) UpdateAllowedSigners(signers []common.Address, allowed bool) error
func (*WorkflowRegistryV2Client) UpsertWorkflow ¶
func (wrc *WorkflowRegistryV2Client) UpsertWorkflow(params RegisterWorkflowV2Parameters) (*TxOutput, error)
Click to show internal directories.
Click to hide internal directories.