forked from LouisAldorio/go-tiktok
/
return_and_refund_.go
69 lines (62 loc) · 3.37 KB
/
return_and_refund_.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
package gotiktok
type SearchReturnRequest struct {
Locale *string `json:"locale" validate:"omitempty,oneof=en-US id-ID"`
OrderIds []string `json:"order_ids" validate:"omitempty"`
CreateTimeGE *int `json:"create_time_ge" validate:"omitempty"`
CreateTimeLT *int `json:"create_time_lt" validate:"omitempty"`
Status *string `json:"status" validate:"omitempty,oneof=RETURN_OR_REFUND_REQUEST_PENDING RETURN_OR_REFUND_REQUEST_REJECTED AWAITING_BUYER_SHIP BUYER_SHIPPED_ITEM REJECT_RECEIVE_PACKAGE RETURN_OR_REFUND_REQUEST_SUCCESS RETURN_OR_REFUND_REQUEST_CANCEL RETURN_OR_REFUND_REQUEST_COMPLETE"`
Type *string `json:"type" validate:"omitempty,oneof=RETURN_AND_REFUND REFUND"`
}
type ReturnOrder struct {
ArbitrationStatus string `json:"arbitration_status"`
CreateTime int `json:"create_time"`
HandoverMethod string `json:"handover_method"`
NextReturnId string `json:"next_return_id"`
OrderId string `json:"order_id"`
PreReturnId string `json:"pre_return_id"`
RefundAmount RefundAmount `json:"refund_amount"`
ReturnID string `json:"return_id"`
ReturnLineItems []ReturnLineItems `json:"return_line_items"`
ReturnProviderId string `json:"return_provider_id"`
ReturnProviderName string `json:"return_provider_name"`
ReturnReason string `json:"return_reason"`
ReturnReasonText string `json:"return_reason_text"`
ReturnStatus string `json:"return_status"`
ReturnTrackingNumber string `json:"return_tracking_number"`
ReturnType string `json:"return_type"`
Role string `json:"role"`
SellerNextActionResponse []SellerNextActionResponse `json:"seller_next_action_response"`
ShipmentType string `json:"shipment_type"`
UpdateTime int `json:"update_time"`
}
type RefundAmount struct {
Currency string `json:"currency"`
RefundShippingFee string `json:"refund_shipping_fee"`
RefundSubtotal string `json:"refund_subtotal"`
RefundTax string `json:"refund_tax"`
RefundTotal string `json:"refund_total"`
}
type ProductImage struct {
Height int `json:"height"`
URL string `json:"url"`
Width int `json:"width"`
}
type ReturnLineItems struct {
OrderLineItemId string `json:"order_line_item_id"`
ProductImage ProductImage `json:"product_image"`
ProductName string `json:"product_name"`
RefundAmount RefundAmount `json:"refund_amount"`
ReturnLineItemId string `json:"return_line_item_id"`
SellerSku string `json:"seller_sku"`
SkuId string `json:"sku_id"`
SkuName string `json:"sku_name"`
}
type SellerNextActionResponse struct {
Action string `json:"action"`
Deadline int `json:"deadline"`
}
type SearchReturnResponse struct {
ReturnOrders []ReturnOrder `json:"return_orders"`
TotalCount int `json:"total_count"`
NextPageToken string `json:"next_page_token"`
}