This repository has been archived by the owner on May 26, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathmodel-toppicks.go
85 lines (77 loc) · 3.36 KB
/
model-toppicks.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
package shopeego
type GetTopPicksListRequest struct {
// Partner ID is assigned upon registration is successful. Required for all requests.
PartnerID int64 `json:"partner_id,omitempty"`
// Shopee's unique identifier for a shop. Required for all requests.
ShopID int64 `json:"shopid,omitempty"`
// This is to indicate the timestamp of the request. Required for all requests.
Timestamp int `json:"timestamp,omitempty"`
}
type GetTopPicksListResponse struct {
// Collection list
Collections []GetTopPicksListResponseCollection `json:"collections,omitempty"`
}
type AddTopPicksRequest struct {
// Collection name. 1 to 24 characters.
Name string `json:"name,omitempty"`
// the list of item id. Allow 4 to 8 items in one collection.
ItemIDs []int `json:"item_i_ds,omitempty"`
// True or False
IsActivated bool `json:"is_activated,omitempty"`
// Partner ID is assigned upon registration is successful. Required for all requests.
PartnerID int64 `json:"partner_id,omitempty"`
// Shopee's unique identifier for a shop. Required for all requests.
ShopID int64 `json:"shopid,omitempty"`
// This is to indicate the timestamp of the request. Required for all requests.
Timestamp int `json:"timestamp,omitempty"`
}
type AddTopPicksResponse struct {
// Collection id
TopPicksID int64 `json:"top_picks_id,omitempty"`
// Whether it is activated or not.
IsActivated bool `json:"is_activated,omitempty"`
// Collection name
Name string `json:"name,omitempty"`
// Item list of the collection
Items []AddTopPicksResponseItem `json:"items,omitempty"`
}
type UpdateTopPicksRequest struct {
// Collection id
TopPicksID int64 `json:"top_picks_id,omitempty"`
// Collection name. 1 to 24 characters.
Name string `json:"name,omitempty"`
// The list of item id. Existed item_ids will overridden by the new_item_ids.
ItemIDs []int `json:"item_i_ds,omitempty"`
// True or False. If true, it will activate this collection and deactivate the original one.
IsActivated bool `json:"is_activated,omitempty"`
// Partner ID is assigned upon registration is successful. Required for all requests.
PartnerID int64 `json:"partner_id,omitempty"`
// Shopee's unique identifier for a shop. Required for all requests.
ShopID int64 `json:"shopid,omitempty"`
// This is to indicate the timestamp of the request. Required for all requests.
Timestamp int `json:"timestamp,omitempty"`
}
type UpdateTopPicksResponse struct {
// Collection id
TopPicksID int64 `json:"top_picks_id,omitempty"`
// Whether it is activated or not.
IsActivated bool `json:"is_activated,omitempty"`
// Collection name
Name string `json:"name,omitempty"`
// Item list of the collection
Items []UpdateTopPicksResponseItem `json:"items,omitempty"`
}
type DeleteTopPicksRequest struct {
// Collection id. Cannot delete an activated collection.
TopPicksID int64 `json:"top_picks_id,omitempty"`
// Partner ID is assigned upon registration is successful. Required for all requests.
PartnerID int64 `json:"partner_id,omitempty"`
// Shopee's unique identifier for a shop. Required for all requests.
ShopID int64 `json:"shopid,omitempty"`
// This is to indicate the timestamp of the request. Required for all requests.
Timestamp int `json:"timestamp,omitempty"`
}
type DeleteTopPicksResponse struct {
// Collection id
TopPicksID int64 `json:"top_picks_id,omitempty"`
}