Documentation
¶
Index ¶
- type AWSInstance
- type Client
- type Cluster
- type ClusterConfig
- type CreateClusterRequest
- type CreateClusterResponse
- type CreateMachineRequest
- type CreateMachineResponse
- type ListAWSPricingResponse
- type ListClustersResponse
- type ProofResponse
- type QueueProofRequest
- type StartProvingRequest
- type SubmitProofRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AWSInstance ¶
type AWSInstance struct { ID int64 `json:"id"` InstanceType string `json:"instance_type"` Region string `json:"region"` HourlyPrice float64 `json:"hourly_price"` InstanceMemory float64 `json:"instance_memory"` VCPU int64 `json:"vcpu"` InstanceStorage string `json:"instance_storage"` CreatedAt string `json:"created_at"` }
type Client ¶
type Client interface { // Clusters CreateCluster(ctx context.Context, req *CreateClusterRequest) (*CreateClusterResponse, error) ListClusters(ctx context.Context) ([]Cluster, error) // Single Machine CreateMachine(ctx context.Context, req *CreateMachineRequest) (*CreateMachineResponse, error) // Proofs QueueProof(ctx context.Context, req *QueueProofRequest) (*ProofResponse, error) StartProving(ctx context.Context, req *StartProvingRequest) (*ProofResponse, error) SubmitProof(ctx context.Context, req *SubmitProofRequest) (*ProofResponse, error) // AWS Pricing ListAWSPricing(ctx context.Context) ([]AWSInstance, error) }
Client defines the interface for interacting with the EthProofs API
type ClusterConfig ¶
type CreateClusterRequest ¶
type CreateClusterRequest struct { Nickname string `json:"nickname"` Description string `json:"description,omitempty"` Hardware string `json:"hardware,omitempty"` CycleType string `json:"cycle_type,omitempty"` ProofType string `json:"proof_type,omitempty"` Configuration []ClusterConfig `json:"configuration"` }
Request/Response types for Clusters
type CreateClusterResponse ¶
type CreateClusterResponse struct {
ID int64 `json:"id"`
}
type CreateMachineRequest ¶
type CreateMachineRequest struct { Nickname string `json:"nickname"` Description string `json:"description,omitempty"` Hardware string `json:"hardware,omitempty"` CycleType string `json:"cycle_type,omitempty"` ProofType string `json:"proof_type,omitempty"` InstanceType string `json:"instance_type"` }
Request/Response types for Single Machine
type CreateMachineResponse ¶
type CreateMachineResponse struct {
ID int64 `json:"id"`
}
type ListAWSPricingResponse ¶
type ListAWSPricingResponse = []AWSInstance
Request/Response types for AWS Pricing
type ListClustersResponse ¶
type ListClustersResponse []Cluster
type ProofResponse ¶
type ProofResponse struct {
ProofID int64 `json:"proof_id"`
}
type QueueProofRequest ¶
type QueueProofRequest struct { BlockNumber int64 `json:"block_number"` ClusterID int64 `json:"cluster_id"` }
Request/Response types for Proofs
type StartProvingRequest ¶
type SubmitProofRequest ¶
Click to show internal directories.
Click to hide internal directories.