Documentation
¶
Index ¶
- Constants
- Variables
- func ExtraModeratorKeyFromReddemScript(redeemScript string) string
- type Images
- type OpenBazaarNode
- func (n *OpenBazaarNode) CalcOrderId(order *pb.Order) (string, error)
- func (n *OpenBazaarNode) CalculateOrderTotal(contract *pb.RicardianContract) (uint64, error)
- func (n *OpenBazaarNode) CancelOfflineOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
- func (n *OpenBazaarNode) CloseDispute(orderId string, buyerPercentage, vendorPercentage float32, resolution string) error
- func (n *OpenBazaarNode) CompleteOrder(orderRatings *OrderRatings, contract *pb.RicardianContract, ...) error
- func (n *OpenBazaarNode) ConfirmOfflineOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
- func (n *OpenBazaarNode) DeleteListing(slug string) error
- func (n *OpenBazaarNode) EncryptMessage(peerID peer.ID, peerKey *libp2p.PubKey, message []byte) (ct []byte, rerr error)
- func (n *OpenBazaarNode) Follow(peerId string) error
- func (n *OpenBazaarNode) FulfillOrder(fulfillment *pb.OrderFulfillment, contract *pb.RicardianContract, ...) error
- func (n *OpenBazaarNode) GetListingCount() int
- func (n *OpenBazaarNode) GetListingFromHash(hash string) (*pb.RicardianContract, []*pb.Inventory, error)
- func (n *OpenBazaarNode) GetListingFromSlug(slug string) (*pb.RicardianContract, []*pb.Inventory, error)
- func (n *OpenBazaarNode) GetListings() ([]byte, error)
- func (n *OpenBazaarNode) GetModeratorFee(transactionTotal uint64) (uint64, error)
- func (n *OpenBazaarNode) GetPeerStatus(peerId string) string
- func (n *OpenBazaarNode) GetProfile() (pb.Profile, error)
- func (n *OpenBazaarNode) IsFulfilled(contract *pb.RicardianContract) bool
- func (n *OpenBazaarNode) IsItemForSale(listing *pb.Listing) bool
- func (n *OpenBazaarNode) NewOrderConfirmation(contract *pb.RicardianContract, addressRequest bool) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) OpenDispute(orderID string, contract *pb.RicardianContract, ...) error
- func (n *OpenBazaarNode) PatchProfile(patch map[string]interface{}) error
- func (n *OpenBazaarNode) ProcessDisputeOpen(rc *pb.RicardianContract, peerID string) error
- func (n *OpenBazaarNode) Purchase(data *PurchaseData) (orderId string, paymentAddress string, paymentAmount uint64, vendorOnline bool, ...)
- func (n *OpenBazaarNode) RefundOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
- func (n *OpenBazaarNode) RejectOfflineOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
- func (n *OpenBazaarNode) ReleaseFunds(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
- func (n *OpenBazaarNode) RemoveSelfAsModerator() error
- func (n *OpenBazaarNode) SeedNode() error
- func (n *OpenBazaarNode) SendCancel(peerId, orderId string) error
- func (n *OpenBazaarNode) SendChat(peerId string, chatMessage *pb.Chat) error
- func (n *OpenBazaarNode) SendDisputeClose(peerId string, k *libp2p.PubKey, resolutionMessage *pb.RicardianContract) error
- func (n *OpenBazaarNode) SendDisputeOpen(peerId string, k *libp2p.PubKey, disputeMessage *pb.RicardianContract) error
- func (n *OpenBazaarNode) SendDisputeUpdate(peerId string, updateMessage *pb.DisputeUpdate) error
- func (n *OpenBazaarNode) SendOfflineAck(peerId string, pointerID peer.ID) error
- func (n *OpenBazaarNode) SendOfflineMessage(p peer.ID, k *libp2p.PubKey, m *pb.Message) error
- func (n *OpenBazaarNode) SendOrder(peerId string, contract *pb.RicardianContract) (resp *pb.Message, err error)
- func (n *OpenBazaarNode) SendOrderCompletion(peerId string, k *libp2p.PubKey, completionMessage *pb.RicardianContract) error
- func (n *OpenBazaarNode) SendOrderConfirmation(peerId string, contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) SendOrderFulfillment(peerId string, k *libp2p.PubKey, fulfillmentMessage *pb.RicardianContract) error
- func (n *OpenBazaarNode) SendRefund(peerId string, refundMessage *pb.RicardianContract) error
- func (n *OpenBazaarNode) SendReject(peerId string, rejectMessage *pb.OrderReject) error
- func (n *OpenBazaarNode) SetAvatarImages(base64ImageData string) (*Images, error)
- func (n *OpenBazaarNode) SetHeaderImages(base64ImageData string) (*Images, error)
- func (n *OpenBazaarNode) SetListingInventory(listing *pb.Listing, inventory []*pb.Inventory) error
- func (n *OpenBazaarNode) SetModeratorsOnListings(moderators []string) error
- func (n *OpenBazaarNode) SetProductImages(base64ImageData, filename string) (*Images, error)
- func (n *OpenBazaarNode) SetSelfAsModerator(moderator *pb.Moderator) error
- func (n *OpenBazaarNode) SignDispute(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignDisputeResolution(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignListing(listing *pb.Listing) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignOrder(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignOrderCompletion(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignOrderConfirmation(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignOrderFulfillment(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) SignRefund(contract *pb.RicardianContract) (*pb.RicardianContract, error)
- func (n *OpenBazaarNode) Unfollow(peerId string) error
- func (n *OpenBazaarNode) UpdateFollow() error
- func (n *OpenBazaarNode) UpdateIndexHashes(hashes map[string]string) error
- func (n *OpenBazaarNode) UpdateListingIndex(contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) UpdateProfile(profile *pb.Profile) error
- func (n *OpenBazaarNode) ValidateAndSaveRating(contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) ValidateCaseContract(contract *pb.RicardianContract) []string
- func (n *OpenBazaarNode) ValidateDirectPaymentAddress(order *pb.Order) error
- func (n *OpenBazaarNode) ValidateDisputeResolution(contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) ValidateModeratedPaymentAddress(order *pb.Order) error
- func (n *OpenBazaarNode) ValidateOrder(contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) ValidateOrderCompletion(contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) ValidateOrderConfirmation(contract *pb.RicardianContract, validateAddress bool) error
- func (n *OpenBazaarNode) ValidateOrderFulfillment(fulfillment *pb.OrderFulfillment, contract *pb.RicardianContract) error
- func (n *OpenBazaarNode) ValidatePaymentAmount(requestedAmount, paymentAmount uint64) bool
- func (n *OpenBazaarNode) VerifySignatureOnDisputeOpen(contract *pb.RicardianContract, peerID string) error
- func (n *OpenBazaarNode) VerifySignaturesOnRefund(contract *pb.RicardianContract) error
- type OrderRatings
- type PurchaseData
- type RatingData
Constants ¶
const (
RatingMin = 1
RatingMax = 5
ReviewMaxCharacters = 3000
)
const (
ListingVersion = 1
TitleMaxCharacters = 140
ShortDescriptionLength = 160
DescriptionMaxCharacters = 50000
MaxTags = 10
MaxCategories = 10
MaxListItems = 30
FilenameMaxCharacters = 255
WordMaxCharacters = 40
SentenceMaxCharacters = 70
PolicyMaxCharacters = 10000
MaxCountryCodes = 255
)
const (
CHAT_MESSAGE_MAX_CHARACTERS = 20000
CHAT_SUBJECT_MAX_CHARACTERS = 500
)
Variables ¶
var (
VERSION = "0.4.3"
USERAGENT = "/openbazaar-go:" + VERSION + "/"
)
var DisputeWg = new(sync.WaitGroup)
var ErrCaseNotFound = errors.New("Case not found")
var ModeratorPointerID multihash.Multihash
Functions ¶
func ExtraModeratorKeyFromReddemScript ¶ added in v0.2.1
func ExtraModeratorKeyFromReddemScript(redeemScript string) string
Types ¶
type Images ¶ added in v0.2.1
type Images struct {
Tiny string `json:"tiny"`
Small string `json:"small"`
Medium string `json:"medium"`
Large string `json:"large"`
Original string `json:"original"`
}
type OpenBazaarNode ¶
type OpenBazaarNode struct {
// Context for issuing IPFS commands
Context commands.Context
// IPFS node object
IpfsNode *core.IpfsNode
/* The roothash of the node directory inside the openbazaar repo.
This directory hash is published on IPNS at our peer ID making
the directory publicly viewable on the network. */
RootHash string
// The path to the openbazaar repo in the file system
RepoPath string
// The OpenBazaar network service for direct communication between peers
Service net.NetworkService
// Database for storing node specific data
Datastore repo.Datastore
// Websocket channel used for pushing data to the UI
Broadcast chan []byte
// Bitcoin wallet implementation
Wallet bitcoin.BitcoinWallet
// Storage for our outgoing messages
MessageStorage sto.OfflineMessagingStorage
// A service that periodically checks the dht for outstanding messages
MessageRetriever *ret.MessageRetriever
// A service that periodically republishes active pointers
PointerRepublisher *rep.PointerRepublisher
// Used to resolve blockchainIDs to OpenBazaar IDs
Resolver *bstk.BlockstackClient
// A service that periodically fetches and caches the bitcoin exchange rates
ExchangeRates bitcoin.ExchangeRates
// An optional gateway URL where we can crosspost data to ensure persistence
CrosspostGateways []*url.URL
// The user-agent for this node
UserAgent string
}
var Node *OpenBazaarNode
func (*OpenBazaarNode) CalcOrderId ¶ added in v0.2.0
func (n *OpenBazaarNode) CalcOrderId(order *pb.Order) (string, error)
func (*OpenBazaarNode) CalculateOrderTotal ¶ added in v0.1.1
func (n *OpenBazaarNode) CalculateOrderTotal(contract *pb.RicardianContract) (uint64, error)
func (*OpenBazaarNode) CancelOfflineOrder ¶ added in v0.2.0
func (n *OpenBazaarNode) CancelOfflineOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) CloseDispute ¶ added in v0.3.0
func (n *OpenBazaarNode) CloseDispute(orderId string, buyerPercentage, vendorPercentage float32, resolution string) error
func (*OpenBazaarNode) CompleteOrder ¶ added in v0.2.2
func (n *OpenBazaarNode) CompleteOrder(orderRatings *OrderRatings, contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) ConfirmOfflineOrder ¶ added in v0.2.0
func (n *OpenBazaarNode) ConfirmOfflineOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) DeleteListing ¶ added in v0.1.1
func (n *OpenBazaarNode) DeleteListing(slug string) error
Deletes the listing directory, removes the listing from the index, and deletes the inventory
func (*OpenBazaarNode) EncryptMessage ¶
func (n *OpenBazaarNode) EncryptMessage(peerID peer.ID, peerKey *libp2p.PubKey, message []byte) (ct []byte, rerr error)
This is a placeholder until the libsignal is operational.
For now we will just encrypt outgoing offline messages with the long lived identity key. Optionally you may provide a public key, to avoid doing an IPFS lookup
func (*OpenBazaarNode) FulfillOrder ¶ added in v0.2.1
func (n *OpenBazaarNode) FulfillOrder(fulfillment *pb.OrderFulfillment, contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) GetListingCount ¶
func (n *OpenBazaarNode) GetListingCount() int
Return the current number of listings
func (*OpenBazaarNode) GetListingFromHash ¶ added in v0.1.1
func (n *OpenBazaarNode) GetListingFromHash(hash string) (*pb.RicardianContract, []*pb.Inventory, error)
func (*OpenBazaarNode) GetListingFromSlug ¶ added in v0.1.1
func (n *OpenBazaarNode) GetListingFromSlug(slug string) (*pb.RicardianContract, []*pb.Inventory, error)
func (*OpenBazaarNode) GetListings ¶ added in v0.2.3
func (n *OpenBazaarNode) GetListings() ([]byte, error)
func (*OpenBazaarNode) GetModeratorFee ¶ added in v0.3.0
func (n *OpenBazaarNode) GetModeratorFee(transactionTotal uint64) (uint64, error)
func (*OpenBazaarNode) GetPeerStatus ¶
func (n *OpenBazaarNode) GetPeerStatus(peerId string) string
func (*OpenBazaarNode) GetProfile ¶
func (n *OpenBazaarNode) GetProfile() (pb.Profile, error)
func (*OpenBazaarNode) IsFulfilled ¶ added in v0.2.1
func (n *OpenBazaarNode) IsFulfilled(contract *pb.RicardianContract) bool
func (*OpenBazaarNode) IsItemForSale ¶ added in v0.2.0
func (n *OpenBazaarNode) IsItemForSale(listing *pb.Listing) bool
Check to see we are selling the given listing. Used when validating an order. FIXME: This wont scale well. We will need to store the hash of active listings in a db to do an indexed search.
func (*OpenBazaarNode) NewOrderConfirmation ¶ added in v0.2.0
func (n *OpenBazaarNode) NewOrderConfirmation(contract *pb.RicardianContract, addressRequest bool) (*pb.RicardianContract, error)
func (*OpenBazaarNode) OpenDispute ¶ added in v0.3.0
func (n *OpenBazaarNode) OpenDispute(orderID string, contract *pb.RicardianContract, records []*spvwallet.TransactionRecord, claim string) error
func (*OpenBazaarNode) PatchProfile ¶ added in v0.4.3
func (n *OpenBazaarNode) PatchProfile(patch map[string]interface{}) error
func (*OpenBazaarNode) ProcessDisputeOpen ¶ added in v0.3.0
func (n *OpenBazaarNode) ProcessDisputeOpen(rc *pb.RicardianContract, peerID string) error
func (*OpenBazaarNode) Purchase ¶
func (n *OpenBazaarNode) Purchase(data *PurchaseData) (orderId string, paymentAddress string, paymentAmount uint64, vendorOnline bool, err error)
func (*OpenBazaarNode) RefundOrder ¶ added in v0.2.1
func (n *OpenBazaarNode) RefundOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) RejectOfflineOrder ¶ added in v0.2.0
func (n *OpenBazaarNode) RejectOfflineOrder(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) ReleaseFunds ¶ added in v0.3.0
func (n *OpenBazaarNode) ReleaseFunds(contract *pb.RicardianContract, records []*spvwallet.TransactionRecord) error
func (*OpenBazaarNode) RemoveSelfAsModerator ¶ added in v0.1.1
func (n *OpenBazaarNode) RemoveSelfAsModerator() error
func (*OpenBazaarNode) SeedNode ¶
func (n *OpenBazaarNode) SeedNode() error
Unpin the current node repo, re-add it, then publish to IPNS
func (*OpenBazaarNode) SendCancel ¶ added in v0.2.0
func (n *OpenBazaarNode) SendCancel(peerId, orderId string) error
func (*OpenBazaarNode) SendChat ¶ added in v0.3.1
func (n *OpenBazaarNode) SendChat(peerId string, chatMessage *pb.Chat) error
func (*OpenBazaarNode) SendDisputeClose ¶ added in v0.3.0
func (n *OpenBazaarNode) SendDisputeClose(peerId string, k *libp2p.PubKey, resolutionMessage *pb.RicardianContract) error
func (*OpenBazaarNode) SendDisputeOpen ¶ added in v0.3.0
func (n *OpenBazaarNode) SendDisputeOpen(peerId string, k *libp2p.PubKey, disputeMessage *pb.RicardianContract) error
func (*OpenBazaarNode) SendDisputeUpdate ¶ added in v0.3.0
func (n *OpenBazaarNode) SendDisputeUpdate(peerId string, updateMessage *pb.DisputeUpdate) error
func (*OpenBazaarNode) SendOfflineAck ¶
func (n *OpenBazaarNode) SendOfflineAck(peerId string, pointerID peer.ID) error
func (*OpenBazaarNode) SendOfflineMessage ¶
func (n *OpenBazaarNode) SendOfflineMessage(p peer.ID, k *libp2p.PubKey, m *pb.Message) error
Supply of a public key is optional, if nil is instead provided n.EncryptMessage does a lookup
func (*OpenBazaarNode) SendOrder ¶ added in v0.1.1
func (n *OpenBazaarNode) SendOrder(peerId string, contract *pb.RicardianContract) (resp *pb.Message, err error)
func (*OpenBazaarNode) SendOrderCompletion ¶ added in v0.2.2
func (n *OpenBazaarNode) SendOrderCompletion(peerId string, k *libp2p.PubKey, completionMessage *pb.RicardianContract) error
func (*OpenBazaarNode) SendOrderConfirmation ¶ added in v0.2.0
func (n *OpenBazaarNode) SendOrderConfirmation(peerId string, contract *pb.RicardianContract) error
func (*OpenBazaarNode) SendOrderFulfillment ¶ added in v0.2.1
func (n *OpenBazaarNode) SendOrderFulfillment(peerId string, k *libp2p.PubKey, fulfillmentMessage *pb.RicardianContract) error
func (*OpenBazaarNode) SendRefund ¶ added in v0.2.1
func (n *OpenBazaarNode) SendRefund(peerId string, refundMessage *pb.RicardianContract) error
func (*OpenBazaarNode) SendReject ¶ added in v0.2.0
func (n *OpenBazaarNode) SendReject(peerId string, rejectMessage *pb.OrderReject) error
func (*OpenBazaarNode) SetAvatarImages ¶ added in v0.2.0
func (n *OpenBazaarNode) SetAvatarImages(base64ImageData string) (*Images, error)
func (*OpenBazaarNode) SetHeaderImages ¶ added in v0.2.0
func (n *OpenBazaarNode) SetHeaderImages(base64ImageData string) (*Images, error)
func (*OpenBazaarNode) SetListingInventory ¶
func (n *OpenBazaarNode) SetListingInventory(listing *pb.Listing, inventory []*pb.Inventory) error
Sets the inventory for the listing in the database. Does some basic validation
to make sure the inventory uses the correct variants.
func (*OpenBazaarNode) SetModeratorsOnListings ¶ added in v0.4.3
func (n *OpenBazaarNode) SetModeratorsOnListings(moderators []string) error
func (*OpenBazaarNode) SetProductImages ¶ added in v0.2.0
func (n *OpenBazaarNode) SetProductImages(base64ImageData, filename string) (*Images, error)
func (*OpenBazaarNode) SetSelfAsModerator ¶ added in v0.1.1
func (n *OpenBazaarNode) SetSelfAsModerator(moderator *pb.Moderator) error
func (*OpenBazaarNode) SignDispute ¶ added in v0.3.0
func (n *OpenBazaarNode) SignDispute(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) SignDisputeResolution ¶ added in v0.3.0
func (n *OpenBazaarNode) SignDisputeResolution(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) SignListing ¶
func (n *OpenBazaarNode) SignListing(listing *pb.Listing) (*pb.RicardianContract, error)
Add our identity to the listing and sign it
func (*OpenBazaarNode) SignOrder ¶ added in v0.2.0
func (n *OpenBazaarNode) SignOrder(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) SignOrderCompletion ¶ added in v0.2.2
func (n *OpenBazaarNode) SignOrderCompletion(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) SignOrderConfirmation ¶ added in v0.2.0
func (n *OpenBazaarNode) SignOrderConfirmation(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) SignOrderFulfillment ¶ added in v0.2.1
func (n *OpenBazaarNode) SignOrderFulfillment(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) SignRefund ¶ added in v0.2.1
func (n *OpenBazaarNode) SignRefund(contract *pb.RicardianContract) (*pb.RicardianContract, error)
func (*OpenBazaarNode) UpdateFollow ¶
func (n *OpenBazaarNode) UpdateFollow() error
This function updates the follow and following lists in the node's root directory
as well as adds the current follow, following, and listing counts to the profile.
We only do this when a user updates his node to avoid needing to make network calls
each time a new follower or unfollow request comes in.
func (*OpenBazaarNode) UpdateIndexHashes ¶ added in v0.4.3
func (n *OpenBazaarNode) UpdateIndexHashes(hashes map[string]string) error
Update the hashes in the index.json file
func (*OpenBazaarNode) UpdateListingIndex ¶
func (n *OpenBazaarNode) UpdateListingIndex(contract *pb.RicardianContract) error
Update the index.json file in the listings directory
func (*OpenBazaarNode) UpdateProfile ¶
func (n *OpenBazaarNode) UpdateProfile(profile *pb.Profile) error
func (*OpenBazaarNode) ValidateAndSaveRating ¶ added in v0.2.2
func (n *OpenBazaarNode) ValidateAndSaveRating(contract *pb.RicardianContract) error
func (*OpenBazaarNode) ValidateCaseContract ¶ added in v0.3.0
func (n *OpenBazaarNode) ValidateCaseContract(contract *pb.RicardianContract) []string
func (*OpenBazaarNode) ValidateDirectPaymentAddress ¶ added in v0.2.0
func (n *OpenBazaarNode) ValidateDirectPaymentAddress(order *pb.Order) error
func (*OpenBazaarNode) ValidateDisputeResolution ¶ added in v0.3.0
func (n *OpenBazaarNode) ValidateDisputeResolution(contract *pb.RicardianContract) error
func (*OpenBazaarNode) ValidateModeratedPaymentAddress ¶ added in v0.2.1
func (n *OpenBazaarNode) ValidateModeratedPaymentAddress(order *pb.Order) error
func (*OpenBazaarNode) ValidateOrder ¶ added in v0.2.0
func (n *OpenBazaarNode) ValidateOrder(contract *pb.RicardianContract) error
func (*OpenBazaarNode) ValidateOrderCompletion ¶ added in v0.2.2
func (n *OpenBazaarNode) ValidateOrderCompletion(contract *pb.RicardianContract) error
func (*OpenBazaarNode) ValidateOrderConfirmation ¶ added in v0.2.1
func (n *OpenBazaarNode) ValidateOrderConfirmation(contract *pb.RicardianContract, validateAddress bool) error
func (*OpenBazaarNode) ValidateOrderFulfillment ¶ added in v0.2.1
func (n *OpenBazaarNode) ValidateOrderFulfillment(fulfillment *pb.OrderFulfillment, contract *pb.RicardianContract) error
func (*OpenBazaarNode) ValidatePaymentAmount ¶ added in v0.4.0
func (n *OpenBazaarNode) ValidatePaymentAmount(requestedAmount, paymentAmount uint64) bool
func (*OpenBazaarNode) VerifySignatureOnDisputeOpen ¶ added in v0.3.0
func (n *OpenBazaarNode) VerifySignatureOnDisputeOpen(contract *pb.RicardianContract, peerID string) error
func (*OpenBazaarNode) VerifySignaturesOnRefund ¶ added in v0.2.1
func (n *OpenBazaarNode) VerifySignaturesOnRefund(contract *pb.RicardianContract) error
type OrderRatings ¶ added in v0.2.2
type OrderRatings struct {
OrderId string `json:"orderId"`
Ratings []RatingData `json:"ratings"`
}
type PurchaseData ¶
type PurchaseData struct {
ShipTo string `json:"shipTo"`
Address string `json:"address"`
City string `json:"city"`
State string `json:"state"`
PostalCode string `json:"postalCode"`
CountryCode string `json:"countryCode"`
AddressNotes string `json:"addressNotes"`
Moderator string `json:"moderator"`
Items []item `json:"items"`
AlternateContactInfo string `json:"alternateContactInfo"`
RefundAddress *string `json:"refundAddress"` //optional, can be left out of json
}
type RatingData ¶ added in v0.2.2
type RatingData struct {
Slug string `json:"slug"`
Overall int `json:"overall"`
Quality int `json:"quality"`
Description int `json:"description"`
DeliverySpeed int `json:"deliverySpeed"`
CustomerService int `json:"customerService"`
Review string `json:"rewview"`
Anonymous bool `json:"anonymous"`
}