added device support

This commit is contained in:
2026-01-10 04:47:04 +03:00
parent d9bfa5ff7f
commit 08c7556960
4 changed files with 15 additions and 12 deletions

View File

@@ -3,9 +3,10 @@ package api
import "resty.dev/v3"
type Client struct {
token string
resty *resty.Client
apiBaseURL string
token string
device string
resty *resty.Client
apiBaseURL string
fiscalEndpoint string
}
@@ -18,9 +19,10 @@ func NewClient(token string) *Client {
}
}
func NewDMClient(token string, dmURL string) *Client {
func NewDMClient(token, dmURL, device string) *Client {
return &Client{
token: token,
device: device,
resty: resty.New(),
apiBaseURL: dmURL,
fiscalEndpoint: "/dm/fiscal",