mirror of
https://github.com/netbirdio/netbird.git
synced 2024-12-24 15:48:52 +01:00
95845c88fe
* feature: add peer GET and DELETE API methods * refactor: extract peer business logic to a separate file * refactor: extract peer business logic to a separate file * feature: add peer update HTTP endpoint * chore: fill peer new fields * merge with main * refactor: HTTP methods according to standards * chore: setup keys POST endpoint without ID
12 lines
380 B
Go
12 lines
380 B
Go
package server
|
|
|
|
type Store interface {
|
|
GetPeer(peerKey string) (*Peer, error)
|
|
DeletePeer(accountId string, peerKey string) (*Peer, error)
|
|
SavePeer(accountId string, peer *Peer) error
|
|
GetAccount(accountId string) (*Account, error)
|
|
GetPeerAccount(peerKey string) (*Account, error)
|
|
GetAccountBySetupKey(setupKey string) (*Account, error)
|
|
SaveAccount(account *Account) error
|
|
}
|