Documentation ¶
Index ¶
Constants ¶
View Source
const Endpoint = "/metros"
Endpoint is the public path for the metros service. Currently unused.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ListResponseItem ¶
type ListResponseItem struct { Code string `json:"code"` Delay time.Duration `json:"delay"` Ipv4 string `json:"ipv4"` Location string `json:"location"` Online bool `json:"online"` Proxy string `json:"proxy"` kcclient.APIResponseCommon }
ListResponseItem is a data item from a response to a /metros/list request. https://docs.kraft.cloud/api/v1/metros/#list-existing-metros
type MetrosService ¶
type MetrosService interface { kcclient.ServiceClient[MetrosService] // Lists all existing metros. This list is currently hard-coded so the // returned result is always the same. // // See: https://docs.kraft.cloud/api/v1/metros/#list-existing-metros List(ctx context.Context, status bool) ([]ListResponseItem, error) }
func NewMetrosClientFromOptions ¶
func NewMetrosClientFromOptions(opts *options.Options) MetrosService
NewMetrosClientFromOptions instantiates a new metro client based on the provided pre-existing options.
Click to show internal directories.
Click to hide internal directories.