sampler-fork/client/backend.go

36 lines
624 B
Go
Raw Normal View History

package client
2019-05-24 02:58:46 +00:00
import (
"github.com/sqshq/sampler/metadata"
"net/http"
)
2019-05-24 02:58:46 +00:00
const (
backendUrl = "http://localhost:8080/api/v1"
registrationPath = "/registration"
reportInstallationPath = "/report/installation"
reportCrashPath = "repost/crash"
)
type BackendClient struct {
client http.Client
}
func NewBackendClient() *BackendClient {
return &BackendClient{
client: http.Client{},
}
}
func (c *BackendClient) ReportInstallation(statistics *metadata.Statistics) {
// TODO
}
func (c *BackendClient) ReportCrash() {
// TODO
}
func (c *BackendClient) Register(key string) {
// TODO
}