update peer model

This commit is contained in:
mr
2026-01-29 13:12:15 +01:00
parent 97cf629e27
commit c1519f6b26
3 changed files with 11 additions and 7 deletions

View File

@@ -61,9 +61,12 @@ func (m PeerRelation) EnumIndex() int {
type Peer struct {
utils.AbstractObject
Verify bool `json:"verify" bson:"verify"`
PeerID string `json:"peer_id" bson:"peer_id" validate:"required"`
Url string `json:"url" bson:"url" validate:"required"` // Url is the URL of the peer (base64url)
Verify bool `json:"verify" bson:"verify"`
PeerID string `json:"peer_id" bson:"peer_id" validate:"required"`
StreamHost string `json:"stream_host" bson:"stream_host" validate:"required"` // Url is the URL of the peer (base64url)
APIUrl string `json:"api_url" bson:"api_url" validate:"required"` // Url is the URL of the peer (base64url)
NATSUrl string `json:"nats_url" bson:"nats_url" validate:"required"`
WalletAddress string `json:"wallet_address" bson:"wallet_address" validate:"required"` // WalletAddress is the wallet address of the peer
PublicKey string `json:"public_key" bson:"public_key" validate:"required"` // PublicKey is the public key of the peer