-
Notifications
You must be signed in to change notification settings - Fork 0
/
client.go
42 lines (35 loc) · 1.03 KB
/
client.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package ptcpayclient
//***********************************************
//* Copyright (c) 2021 Ulbora Labs LLC
//* Copyright (c) 2021 Ken Williamson
//***********************************************
const (
userAgent = "Ulbora btyPayClient"
)
// go mod init github.com/Ulbora/BTCPayClient
//Headers Headers
type Headers struct {
headers map[string]string
//mu sync.Mutex
}
//Set Set
func (h *Headers) Set(key string, value string) {
//h.mu.Lock()
//defer h.mu.Unlock()
if h.headers == nil {
h.headers = make(map[string]string)
}
h.headers[key] = value
}
//Client Client
type Client interface {
//GetClientID() string
//Token(req *TokenRequest) *TokenResponse
//PairClient(code string) *TokenResponse
//GetPairingCodeRequest(code string) string
//GetRates(currencyPairs []string, storeID string) *RateResponse
//CreateInvoice(inv *InvoiceReq) *InvoiceResponse
//GetInvoice(invoiceID string) *InvoiceResponse
//GetInvoices(args *InvoiceArgs) *InvoiceListResponse
}
// go mod init github.com/Ulbora/BTCPayClientGreenfieldV1