-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathtypes.go
120 lines (99 loc) · 2.6 KB
/
types.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
package helheim_go
type SessionAwareResponse struct {
SessionId int `json:"sessionID"`
}
type ErrorAwareResponse struct {
Error bool `json:"error"`
ErrorMsg string `json:"errorMsg"`
}
type AuthResponse struct {
SessionAwareResponse
Response string `json:"response"`
}
type BalanceResponse struct {
ErrorAwareResponse
SessionAwareResponse
Response struct {
Balance int `json:"balance"`
IsExpired bool `json:"isExpired"`
Expiry int `json:"expiry"`
} `json:"response"`
}
type SessionResponse struct {
ErrorAwareResponse
SessionAwareResponse
Headers map[string]string `json:"headers"`
Cookies []SessionCookie `json:"cookies"`
}
type SessionCookie struct {
Name string `json:"name,omitempty"`
Value string `json:"value,omitempty"`
Domain string `json:"domain,omitempty"`
Path string `json:"path,omitempty"`
Expires int `json:"expires,omitempty"`
}
type ModifyCookiesResponse struct {
ErrorAwareResponse
SessionAwareResponse
Cookies []SessionCookie `json:"cookies"`
}
type RequestResponse struct {
ErrorAwareResponse
SessionAwareResponse
Session RequestResponseSession `json:"session"`
Response RequestResponseResponse `json:"response"`
}
type RequestResponseSession struct {
Headers map[string]string `json:"headers"`
Cookies []SessionCookie `json:"cookies"`
}
type RequestResponseResponse struct {
Headers map[string]string `json:"headers"`
Cookies map[string]string `json:"cookies"`
StatusCode int `json:"status_code"`
Body string `json:"body"`
Content string `json:"content"`
}
type SessionDeleteResponse struct {
ErrorAwareResponse
SessionAwareResponse
}
type SetHeadersResponse struct {
ErrorAwareResponse
SessionAwareResponse
}
type SetProxyResponse struct {
ErrorAwareResponse
SessionAwareResponse
}
type WokouResponse struct {
ErrorAwareResponse
SessionAwareResponse
Response string `json:"response"`
}
type CreateSessionOptions struct {
Browser BrowserOptions `json:"browser"`
Captcha CaptchaOptions `json:"captcha"`
}
type BrowserOptions struct {
Browser string `json:"browser"`
Mobile bool `json:"mobile"`
Platform string `json:"platform"`
}
type CaptchaOptions struct {
Provider string `json:"provider"`
}
type RequestOptions struct {
Method string `json:"method"`
Url string `json:"url"`
Options map[string]string `json:"options"`
}
type requestOptionsInternal struct {
Method string `json:"method"`
Url string `json:"url"`
Options map[string]string `json:"options"`
}
type KasadaOptions struct {
}
type KasadaHooksOptions struct {
}