// getBlockAPI returns a block api for listing blocks. func getBlockAPI(c *envcmd.EnvCommandBase) (block.BlockListAPI, error) { root, err := c.NewAPIRoot() if err != nil { return nil, err } return apiblock.NewClient(root), nil }
func connectionCredentials(c envcmd.EnvCommandBase) (configstore.APICredentials, error) { return c.ConnectionCredentials() }
func connectionEndpoint(c envcmd.EnvCommandBase, refresh bool) (configstore.APIEndpoint, error) { return c.ConnectionEndpoint(refresh) }