blob: 368a111a045a2c19a3f7afc04baf72f4d7e3e74b (
plain)
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
|
package profitbricks
// Endpoint is the base url for REST requests.
var Endpoint = "https://api.profitbricks.com/cloudapi/v4"
// Username for authentication .
var Username string
// Password for authentication .
var Passwd string
// SetEndpoint is used to set the REST Endpoint. Endpoint is declared in config.go
func SetEndpoint(newendpoint string) string {
if newendpoint != "" {
Endpoint = newendpoint
}
return Endpoint
}
// SetAuth is used to set Username and Passwd. Username and Passwd are declared in config.go
func SetAuth(u, p string) {
Username = u
Passwd = p
}
func SetUserAgent(userAgent string) {
AgentHeader = userAgent
}
|