smdclient

package
v0.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 7, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnmarshal = errors.New("cannot unmarshal JSON")
)

Functions

This section is empty.

Types

type SMDClient

type SMDClient struct {
	// contains filtered or unexported fields
}

SMDClient is a client for SMD

func NewSMDClient

func NewSMDClient(baseurl string, jwt string) *SMDClient

NewSMDClient creates a new SMDClient which connects to the SMD server at baseurl and uses the provided JWT for authentication

func (*SMDClient) GroupMembership

func (s *SMDClient) GroupMembership(id string) ([]string, error)

GroupMembership returns the group labels for the xname with the given ID

func (*SMDClient) IDfromMAC

func (s *SMDClient) IDfromMAC(mac string) (string, error)

IDfromMAC returns the ID of the xname that has the MAC address

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL