abstractCloud
Hierarchy
- Cloud
Index
Constructors
Properties
Methods
Constructors
constructor
Parameters
params: { args?: string; cache: string; chain: blockchain; developer: string; id: string; isLocalCloud?: boolean; jobId: string; metadata?: string; repo: string; stepId: string; task?: string; taskId: string; userId?: string }
the parameters for the Cloud class
Returns Cloud
Properties
optionalreadonlyargs
readonlycache
readonlychain
readonlydeveloper
readonlyid
readonlyisLocalCloud
readonlyjobId
optionalreadonlymetadata
readonlyrepo
readonlystepId
optionalreadonlytask
readonlytaskId
optionalreadonlyuserId
Methods
abstractaddTask
Abstract method to add the task Used to add the task
Parameters
data: { args?: string; maxAttempts?: number; metadata?: string; startTime?: number; task: string; userId?: string }
the data
Returns Promise<string>
the task id
abstractdecrypt
Abstract method to decrypt the data
Parameters
params: { context: string; data: string; keyId?: string }
Returns Promise<undefined | string>
abstractdeleteTask
Abstract method to delete the task Used to delete the task
Parameters
taskId: string
the task id
Returns Promise<void>
abstractdeleteTransaction
Abstract method to delete the transaction Used to delete the transaction
Parameters
txId: string
the transaction id
Returns Promise<void>
abstractencrypt
Abstract method to encrypt the data
Parameters
params: { context: string; data: string; keyId?: string }
Returns Promise<undefined | string>
abstractexecute
Abstract method to execute the transactions Used to execute the transactions
Parameters
data: { args?: string; metadata?: string; task: string; transactions: string[]; userId?: string }
the data
Returns Promise<string>
the result
abstractforceWorkerRestart
forces the worker to restart the AWS lambda container See https://github.com/o1-labs/o1js/issues/1651
Returns Promise<void>
abstractgetDataByKey
Abstract method to get the data by key Used to get the data by key from the cloud storage
Parameters
key: string
the key
Returns Promise<undefined | string>
the value of the key
abstractgetDeployer
Abstract method to get the deployer key pair Used to get the public and private keys of the deployer for test networks only Devnet and Zeko are supported
Returns Promise<undefined | DeployerKeyPair>
the deployer key pair
abstractgetTransactions
Abstract method to get the transactions Used to get the transactions
Returns Promise<CloudTransaction[]>
the transactions
abstractjobResult
Abstract method to get the job result Used to get the job result
Parameters
jobId: string
the job id
Returns Promise<undefined | JobData>
the job result
abstractloadFile
Abstract method to load the file Used to load the file from the cloud storage
Parameters
filename: string
the filename
Returns Promise<undefined | Buffer>
the value of the file
abstractprocessTasks
Abstract method to process the tasks
Returns Promise<void>
abstractpublishTransactionMetadata
Publish the transaction metadata in human-readable format
Parameters
params: { metadata: TransactionMetadata; txId: string }
Returns Promise<void>
abstractrecursiveProof
Abstract method to calculate the recursive proof Used to calculate the recursive proof
Parameters
data: { args?: string; metadata?: string; task?: string; transactions: string[]; userId?: string }
the data
Returns Promise<string>
the proof
abstractreleaseDeployer
Abstract method to release the deployer
Parameters
params: { publicKey: string; txsHashes: string[] }
the public key of the deployer and the transactions hashes Used to release the deployer after the transactions are sent to the blockchain
Returns Promise<void>
abstractsaveDataByKey
Abstract method to save the data by key Used to save the data by key to the cloud storage
Parameters
key: string
the key
value: undefined | string
the value
Returns Promise<void>
abstractsaveFile
Abstract method to save the file Used to save the file to the cloud storage
Parameters
filename: string
the filename
value: Buffer
the value
Returns Promise<void>
abstractsendTransactions
Abstract method to send the transactions
Parameters
transactions: string[] | CloudTransaction[]
Returns Promise<CloudTransaction[]>
Constructor for the Cloud class