Files
platiparser/plati/client.go
dilap54 3bbc6a0baa
All checks were successful
Build and push image / deploy (push) Successful in 1m44s
add parsing sumpays
2023-12-27 00:15:55 +03:00

28 lines
460 B
Go

package plati
import (
"math/rand"
"net/http"
)
type Client struct {
httpClis []*http.Client
token string
sellerID int
guidAgent string
}
func New(clients []*http.Client) *Client {
return &Client{
httpClis: clients,
token: "7C731D89FED84B479B89F24F81BB8AF2",
sellerID: 1209592,
guidAgent: "98232A21641B4DF0B13FE96A48CCAD9E",
}
}
func (c *Client) httpCli() *http.Client {
i := rand.Intn(len(c.httpClis))
return c.httpClis[i]
}