seekia/internal/network/trustedFundedStatus/trustedFundedStatus.go

68 lines
1.7 KiB
Go
Raw Normal View History

// trustedFundedStatus provides functions to store and retrieve the trusted funded status of identities, messages, profiles, and reports
// "trusted" means we are retrieving funded statuses from hosts
// This is different from verifiedFundedStatus, which retrieves the statuses from the account credit servers
package trustedFundedStatus
// For our own funded statuses, we use different packages:
// myIdentityBalance for our identities, and myFundedStatus for content
// This is because we want to use the account credit servers for our own statuses,
// and we want to store the statuses in myDatastores instead of the badgerDatabase
//TODO: Build this package
// We need to make fundedStatus requests to hosts
// We should store the statuses in badgerDatabase
// If a status has not been checked in 1 month, it should be considered unknown
//Outputs:
// -bool: Funded status is known
// -bool: Identity is funded
// -int64: Last time we checked
// -error
func GetTrustedIdentityIsFundedStatus(userIdentityHash [16]byte, networkType byte)(bool, bool, int64, error){
//TODO
return true, true, 0, nil
}
//Outputs:
// -bool: Funded status is known
// -bool: Profile is funded
// -error
func GetTrustedMateProfileIsFundedStatus(profileHash [28]byte)(bool, bool, error){
//TODO
return true, true, nil
}
//Outputs:
// -bool: Funded status is known
// -bool: Message is funded
// -error
func GetTrustedMessageIsFundedStatus(messageHash [26]byte)(bool, bool, error){
//TODO
return true, true, nil
}
//Outputs:
// -bool: Funded status is known
// -bool: Report is funded
// -error
func GetTrustedReportIsFundedStatus(reportHash [30]byte)(bool, bool, error){
//TODO
return true, true, nil
}