Update November 20, 2024 (#122)
This commit is contained in:
48
ozon/fbs.go
48
ozon/fbs.go
@@ -3186,3 +3186,51 @@ func (c FBS) SplitOrder(ctx context.Context, params *SplitOrderParams) (*SplitOr
|
||||
|
||||
return resp, nil
|
||||
}
|
||||
|
||||
type ListUnpaidProductsParams struct {
|
||||
// Cursor for the next data sample
|
||||
Cursor string `json:"cursor"`
|
||||
|
||||
// Number of values in the response
|
||||
Limit int32 `json:"limit,omitempty"`
|
||||
}
|
||||
|
||||
type ListUnpaidProductsResponse struct {
|
||||
core.CommonResponse
|
||||
|
||||
Products []UnpaidProduct `json:"products"`
|
||||
|
||||
// Cursor for the next data sample
|
||||
Cursor string `json:"cursor"`
|
||||
}
|
||||
|
||||
type UnpaidProduct struct {
|
||||
// Product identifier
|
||||
ProductId int64 `json:"product_id"`
|
||||
|
||||
// Product identifier in the seller's system
|
||||
OfferId string `json:"offer_id"`
|
||||
|
||||
// Product quantity, pcs
|
||||
Quantity int32 `json:"quantity"`
|
||||
|
||||
// Product name
|
||||
Name string `json:"name"`
|
||||
|
||||
// Link to product image
|
||||
ImageURL string `json:"image_url"`
|
||||
}
|
||||
|
||||
func (c FBS) ListUnpaidProducts(ctx context.Context, params *ListUnpaidProductsParams) (*ListUnpaidProductsResponse, error) {
|
||||
url := "/v1/posting/unpaid-legal/product/list"
|
||||
|
||||
resp := &ListUnpaidProductsResponse{}
|
||||
|
||||
response, err := c.client.Request(ctx, http.MethodPost, url, params, resp, nil)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
response.CopyCommonResponse(&resp.CommonResponse)
|
||||
|
||||
return resp, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user