Documentation
¶
Index ¶
- type AddPieceRequest
- type AddPieceResponse
- type AddRootsRequest
- type AddRootsResponse
- type CreateProofSetRequest
- type CreateProofSetResponse
- type FoundPieceResponse
- type GetProofSetResponse
- type GetProofSetStateResponse
- type GetProviderStatusResponse
- type ListProofSetsResponse
- type PieceHash
- type ProofSetContractState
- type ProofSetEntry
- type ProofSetStatusResponse
- type RegisterProviderRequest
- type RegisterProviderResponse
- type RemoveRootResponse
- type Root
- type RootEntry
- type SubrootEntry
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddPieceRequest ¶
type AddPieceResponse ¶
type AddRootsResponse ¶
type AddRootsResponse struct {
TxHash string `json:"txHash"`
}
AddRoots types
type CreateProofSetRequest ¶
type CreateProofSetRequest struct {
RecordKeeper string `json:"recordKeeper"`
}
CreateProofSet types
type CreateProofSetResponse ¶
type CreateProofSetResponse struct {
TxHash string `json:"txHash"`
Location string `json:"location"`
}
CreateProofSet types
type FoundPieceResponse ¶
type FoundPieceResponse struct {
PieceCID string `json:"piece_cid"`
}
type GetProofSetResponse ¶
type GetProofSetResponse struct {
ID uint64 `json:"id"`
NextChallengeEpoch *int64 `json:"nextChallengeEpoch"`
Roots []RootEntry `json:"roots"`
// piri only - optinal
PreviousChallengeEpoch *int64 `json:"previousChallengeEpoch,omitempty"`
ProvingPeriod *int64 `json:"provingPeriod,omitempty"`
ChallengeWindow *int64 `json:"challengeWindow,omitempty"`
}
GetProofSet types
type GetProofSetStateResponse ¶ added in v0.0.15
type GetProofSetStateResponse struct {
ID uint64 `json:"id"`
// if the proof set has been initialized with a root, and is expecting proofs to be submitted.
Initialized bool `json:"initialized"`
// When the next challenge for a proof will be issued
NextChallengeEpoch int64 `json:"nextChallengeEpoch"`
// When the last challenge for a proof was issued
PreviousChallengeEpoch int64 `json:"previousChallengeEpoch"`
// The proving period of this proof set
ProvingPeriod int64 `json:"provingPeriod"`
// The challenge window of this proof set
ChallengeWindow int64 `json:"challengeWindow"`
// The current epoch of the chain
CurrentEpoch int64 `json:"currentEpoch"`
// true if a challenge has been issued: CurrentEpoch >= NextChallengeEpoch
ChallengedIssued bool `json:"challengedIssued"`
// true if in challenge window: CurrentEpoch < NextChallengeEpoch + ChallengeWindow
InChallengeWindow bool `json:"inChallengeWindow"`
// true if we missed the challenge: CurrentEpoch > NextChallengeEpoch + ChallengeWindow
IsInFaultState bool `json:"isInFaultState"`
// true if we submitted a proof for the current ChallengeWindow
HasProven bool `json:"hasProven"`
// true if the node is currently generating a proof
IsProving bool `json:"isProving"`
// the state of the proof set present in the contract
ContractState ProofSetContractState `json:"contractState"`
}
type GetProviderStatusResponse ¶ added in v0.0.17
type GetProviderStatusResponse struct {
ID uint64 `json:"id"`
Address string `json:"address"`
Payee string `json:"payee"`
IsRegistered bool `json:"isRegistered"`
IsActive bool `json:"isActive"`
Name string `json:"name"`
Description string `json:"description"`
RegistrationStatus string `json:"registrationStatus"`
IsApproved bool `json:"isApproved"`
}
GetProviderStatus types
type ListProofSetsResponse ¶
type ListProofSetsResponse []ProofSetEntry
type ProofSetContractState ¶ added in v0.0.15
type ProofSetContractState struct {
// owners of the proof set
Owners []common.Address `json:"owners"`
// The start of the NEXT OPEN proving period's challenge window
NextChallengeWindowStart uint64 `json:"nextChallengeWindowStart"`
// the epoch of the next challenge
NextChallengeEpoch uint64 `json:"nextChallengeEpoch"`
// Max number of epochs between two consecutive proofs
MaxProvingPeriod uint64 `json:"maxProvingPeriod"`
// challengeWindow Number of epochs for the challenge window
ChallengeWindow uint64 `json:"challengeWindow"`
//index of the most recently added leaf that is challengeable in the current proving period
ChallengeRange uint64 `json:"challengeRange"`
// piece ids of the pieces scheduled for removal at the start of the next proving period
ScheduledRemovals []uint64 `json:"scheduledRemovals"`
// estimated cost of submitting a proof
ProofFee uint64 `json:"proofFee"`
// estimated cost of submitting a proof with buffer applied
ProofFeeBuffered uint64 `json:"proofFeeBuffered"`
}
type ProofSetEntry ¶
type ProofSetEntry struct {
ID uint64 `json:"id"`
Initialized bool `json:"initialized"`
Roots []RootEntry `json:"roots"`
NextChallengeEpoch *int64 `json:"nextChallengeEpoch,omitempty"`
PreviousChallengeEpoch *int64 `json:"previousChallengeEpoch,omitempty"`
ProvingPeriod *int64 `json:"provingPeriod,omitempty"`
ChallengeWindow *int64 `json:"challengeWindow,omitempty"`
}
type ProofSetStatusResponse ¶
type ProofSetStatusResponse struct {
CreateMessageHash string `json:"createMessageHash"`
ProofsetCreated bool `json:"proofsetCreated"`
Service string `json:"service"`
TxStatus string `json:"txStatus"`
OK *bool `json:"ok"`
ProofSetId *uint64 `json:"proofSetId,omitempty"`
}
GetProofSetStatus types
type RegisterProviderRequest ¶ added in v0.0.17
type RegisterProviderRequest struct {
Name string `json:"name"`
Description string `json:"description"`
}
RegisterProvider types
type RegisterProviderResponse ¶ added in v0.0.17
type RegisterProviderResponse struct {
TxHash string `json:"txHash,omitempty"`
Address string `json:"address,omitempty"`
Payee string `json:"payee,omitempty"`
ID uint64 `json:"id,omitempty"`
IsActive bool `json:"isActive,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
}
RegisterProvider types
type RemoveRootResponse ¶
type RemoveRootResponse struct {
TxHash string `json:"txHash"`
}
type Root ¶
type Root struct {
RootCID string `json:"rootCid"`
Subroots []SubrootEntry `json:"subroots"`
}
AddRoots types
type RootEntry ¶
type RootEntry struct {
RootID uint64 `json:"rootId"`
RootCID string `json:"rootCid"`
SubrootCID string `json:"subrootCid"`
SubrootOffset int64 `json:"subrootOffset"`
}
GetProofSet types
type SubrootEntry ¶
type SubrootEntry struct {
SubrootCID string `json:"subrootCid"`
}
AddRoots types
Click to show internal directories.
Click to hide internal directories.