Documentation
¶
Index ¶
Constants ¶
View Source
const ( // AppTopicSession represents the session change topic. AppTopicSession = "Session change" // AppTopicDataTransferred represents the data transfer topic. AppTopicDataTransferred = "Session data transferred" // AppTopicTokensEarned is a topic for publish events about tokens earned as a provider. AppTopicTokensEarned = "SessionTokensEarned" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppEventDataTransferred ¶
AppEventDataTransferred represents the data transfer event
type AppEventSession ¶
type AppEventSession struct { Status Status Service ServiceContext Session SessionContext }
AppEventSession represents the session change payload
type AppEventTokensEarned ¶
AppEventTokensEarned is an update on tokens earned during current session
type ServiceContext ¶
type ServiceContext struct {
ID string
}
ServiceContext holds service context metadata
type SessionContext ¶
type SessionContext struct { ID string StartedAt time.Time ConsumerID identity.Identity ConsumerLocation market.Location HermesID common.Address Proposal market.ServiceProposal }
SessionContext holds session context metadata
type Status ¶
type Status string
Status represents the different actions that might happen on a session
const ( // CreatedStatus indicates a session has been created CreatedStatus Status = "CreatedStatus" // RemovedStatus indicates a session has been removed RemovedStatus Status = "RemovedStatus" // AcknowledgedStatus indicates a session has been reported as a success from consumer side AcknowledgedStatus Status = "AcknowledgedStatus" )
Click to show internal directories.
Click to hide internal directories.