feat: shit shit

This commit is contained in:
2025-08-15 11:10:28 +03:00
parent 0c86228095
commit 38acc4a443
1402 changed files with 453050 additions and 111 deletions

View File

@@ -10,6 +10,7 @@ import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
unsafe "unsafe"
)
@@ -20,20 +21,931 @@ const (
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type CalculateProductTariffsRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
MarketplaceId int64 `protobuf:"varint,1,opt,name=marketplace_id,json=marketplaceId,proto3" json:"marketplace_id,omitempty"`
Parameters *CalculateProductTariffsRequest_Parameters `protobuf:"bytes,2,opt,name=parameters,proto3" json:"parameters,omitempty"`
Offers []*CalculateProductTariffsRequest_Offers `protobuf:"bytes,3,rep,name=offers,proto3" json:"offers,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsRequest) Reset() {
*x = CalculateProductTariffsRequest{}
mi := &file_yandexmarket_products_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsRequest) ProtoMessage() {}
func (x *CalculateProductTariffsRequest) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[0]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsRequest.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsRequest) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{0}
}
func (x *CalculateProductTariffsRequest) GetMarketplaceId() int64 {
if x != nil {
return x.MarketplaceId
}
return 0
}
func (x *CalculateProductTariffsRequest) GetParameters() *CalculateProductTariffsRequest_Parameters {
if x != nil {
return x.Parameters
}
return nil
}
func (x *CalculateProductTariffsRequest) GetOffers() []*CalculateProductTariffsRequest_Offers {
if x != nil {
return x.Offers
}
return nil
}
type CalculateProductTariffsResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Offers []*CalculateProductTariffsResponse_Offers `protobuf:"bytes,1,rep,name=offers,proto3" json:"offers,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsResponse) Reset() {
*x = CalculateProductTariffsResponse{}
mi := &file_yandexmarket_products_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsResponse) ProtoMessage() {}
func (x *CalculateProductTariffsResponse) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[1]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsResponse.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsResponse) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{1}
}
func (x *CalculateProductTariffsResponse) GetOffers() []*CalculateProductTariffsResponse_Offers {
if x != nil {
return x.Offers
}
return nil
}
type GetProductsRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
MarketplaceId int64 `protobuf:"varint,1,opt,name=marketplace_id,json=marketplaceId,proto3" json:"marketplace_id,omitempty"`
OfferIds []string `protobuf:"bytes,2,rep,name=offer_ids,json=offerIds,proto3" json:"offer_ids,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetProductsRequest) Reset() {
*x = GetProductsRequest{}
mi := &file_yandexmarket_products_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetProductsRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetProductsRequest) ProtoMessage() {}
func (x *GetProductsRequest) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[2]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetProductsRequest.ProtoReflect.Descriptor instead.
func (*GetProductsRequest) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{2}
}
func (x *GetProductsRequest) GetMarketplaceId() int64 {
if x != nil {
return x.MarketplaceId
}
return 0
}
func (x *GetProductsRequest) GetOfferIds() []string {
if x != nil {
return x.OfferIds
}
return nil
}
type GetProductsResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Offers []*GetProductsResponse_Offer `protobuf:"bytes,1,rep,name=offers,proto3" json:"offers,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetProductsResponse) Reset() {
*x = GetProductsResponse{}
mi := &file_yandexmarket_products_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetProductsResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetProductsResponse) ProtoMessage() {}
func (x *GetProductsResponse) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[3]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetProductsResponse.ProtoReflect.Descriptor instead.
func (*GetProductsResponse) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{3}
}
func (x *GetProductsResponse) GetOffers() []*GetProductsResponse_Offer {
if x != nil {
return x.Offers
}
return nil
}
type CalculateProductTariffsRequest_Offers struct {
state protoimpl.MessageState `protogen:"open.v1"`
CategoryId int64 `protobuf:"varint,1,opt,name=category_id,json=categoryId,proto3" json:"category_id,omitempty"`
Price int64 `protobuf:"varint,2,opt,name=price,proto3" json:"price,omitempty"`
Length int64 `protobuf:"varint,3,opt,name=length,proto3" json:"length,omitempty"`
Width int64 `protobuf:"varint,4,opt,name=width,proto3" json:"width,omitempty"`
Height int64 `protobuf:"varint,5,opt,name=height,proto3" json:"height,omitempty"`
Weight int64 `protobuf:"varint,6,opt,name=weight,proto3" json:"weight,omitempty"`
Quantity int64 `protobuf:"varint,7,opt,name=quantity,proto3" json:"quantity,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsRequest_Offers) Reset() {
*x = CalculateProductTariffsRequest_Offers{}
mi := &file_yandexmarket_products_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsRequest_Offers) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsRequest_Offers) ProtoMessage() {}
func (x *CalculateProductTariffsRequest_Offers) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[4]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsRequest_Offers.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsRequest_Offers) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{0, 0}
}
func (x *CalculateProductTariffsRequest_Offers) GetCategoryId() int64 {
if x != nil {
return x.CategoryId
}
return 0
}
func (x *CalculateProductTariffsRequest_Offers) GetPrice() int64 {
if x != nil {
return x.Price
}
return 0
}
func (x *CalculateProductTariffsRequest_Offers) GetLength() int64 {
if x != nil {
return x.Length
}
return 0
}
func (x *CalculateProductTariffsRequest_Offers) GetWidth() int64 {
if x != nil {
return x.Width
}
return 0
}
func (x *CalculateProductTariffsRequest_Offers) GetHeight() int64 {
if x != nil {
return x.Height
}
return 0
}
func (x *CalculateProductTariffsRequest_Offers) GetWeight() int64 {
if x != nil {
return x.Weight
}
return 0
}
func (x *CalculateProductTariffsRequest_Offers) GetQuantity() int64 {
if x != nil {
return x.Quantity
}
return 0
}
type CalculateProductTariffsRequest_Parameters struct {
state protoimpl.MessageState `protogen:"open.v1"`
CampaignId int64 `protobuf:"varint,1,opt,name=campaign_id,json=campaignId,proto3" json:"campaign_id,omitempty"`
SellingProgram string `protobuf:"bytes,2,opt,name=selling_program,json=sellingProgram,proto3" json:"selling_program,omitempty"`
Frequency string `protobuf:"bytes,3,opt,name=frequency,proto3" json:"frequency,omitempty"`
Currency string `protobuf:"bytes,4,opt,name=currency,proto3" json:"currency,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsRequest_Parameters) Reset() {
*x = CalculateProductTariffsRequest_Parameters{}
mi := &file_yandexmarket_products_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsRequest_Parameters) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsRequest_Parameters) ProtoMessage() {}
func (x *CalculateProductTariffsRequest_Parameters) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[5]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsRequest_Parameters.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsRequest_Parameters) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{0, 1}
}
func (x *CalculateProductTariffsRequest_Parameters) GetCampaignId() int64 {
if x != nil {
return x.CampaignId
}
return 0
}
func (x *CalculateProductTariffsRequest_Parameters) GetSellingProgram() string {
if x != nil {
return x.SellingProgram
}
return ""
}
func (x *CalculateProductTariffsRequest_Parameters) GetFrequency() string {
if x != nil {
return x.Frequency
}
return ""
}
func (x *CalculateProductTariffsRequest_Parameters) GetCurrency() string {
if x != nil {
return x.Currency
}
return ""
}
type CalculateProductTariffsResponse_Offer struct {
state protoimpl.MessageState `protogen:"open.v1"`
CategoryId int64 `protobuf:"varint,1,opt,name=category_id,json=categoryId,proto3" json:"category_id,omitempty"`
Price int64 `protobuf:"varint,2,opt,name=price,proto3" json:"price,omitempty"`
Length int64 `protobuf:"varint,3,opt,name=length,proto3" json:"length,omitempty"`
Width int64 `protobuf:"varint,4,opt,name=width,proto3" json:"width,omitempty"`
Height int64 `protobuf:"varint,5,opt,name=height,proto3" json:"height,omitempty"`
Weight int64 `protobuf:"varint,6,opt,name=weight,proto3" json:"weight,omitempty"`
Quantity int64 `protobuf:"varint,7,opt,name=quantity,proto3" json:"quantity,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsResponse_Offer) Reset() {
*x = CalculateProductTariffsResponse_Offer{}
mi := &file_yandexmarket_products_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsResponse_Offer) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsResponse_Offer) ProtoMessage() {}
func (x *CalculateProductTariffsResponse_Offer) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[6]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsResponse_Offer.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsResponse_Offer) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{1, 0}
}
func (x *CalculateProductTariffsResponse_Offer) GetCategoryId() int64 {
if x != nil {
return x.CategoryId
}
return 0
}
func (x *CalculateProductTariffsResponse_Offer) GetPrice() int64 {
if x != nil {
return x.Price
}
return 0
}
func (x *CalculateProductTariffsResponse_Offer) GetLength() int64 {
if x != nil {
return x.Length
}
return 0
}
func (x *CalculateProductTariffsResponse_Offer) GetWidth() int64 {
if x != nil {
return x.Width
}
return 0
}
func (x *CalculateProductTariffsResponse_Offer) GetHeight() int64 {
if x != nil {
return x.Height
}
return 0
}
func (x *CalculateProductTariffsResponse_Offer) GetWeight() int64 {
if x != nil {
return x.Weight
}
return 0
}
func (x *CalculateProductTariffsResponse_Offer) GetQuantity() int64 {
if x != nil {
return x.Quantity
}
return 0
}
type CalculateProductTariffsResponse_Parameter struct {
state protoimpl.MessageState `protogen:"open.v1"`
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsResponse_Parameter) Reset() {
*x = CalculateProductTariffsResponse_Parameter{}
mi := &file_yandexmarket_products_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsResponse_Parameter) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsResponse_Parameter) ProtoMessage() {}
func (x *CalculateProductTariffsResponse_Parameter) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[7]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsResponse_Parameter.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsResponse_Parameter) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{1, 1}
}
func (x *CalculateProductTariffsResponse_Parameter) GetName() string {
if x != nil {
return x.Name
}
return ""
}
func (x *CalculateProductTariffsResponse_Parameter) GetValue() string {
if x != nil {
return x.Value
}
return ""
}
type CalculateProductTariffsResponse_Tariff struct {
state protoimpl.MessageState `protogen:"open.v1"`
Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
Amount int64 `protobuf:"varint,2,opt,name=amount,proto3" json:"amount,omitempty"`
Currency string `protobuf:"bytes,3,opt,name=currency,proto3" json:"currency,omitempty"`
Parameters []*CalculateProductTariffsResponse_Parameter `protobuf:"bytes,4,rep,name=parameters,proto3" json:"parameters,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsResponse_Tariff) Reset() {
*x = CalculateProductTariffsResponse_Tariff{}
mi := &file_yandexmarket_products_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsResponse_Tariff) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsResponse_Tariff) ProtoMessage() {}
func (x *CalculateProductTariffsResponse_Tariff) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[8]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsResponse_Tariff.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsResponse_Tariff) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{1, 2}
}
func (x *CalculateProductTariffsResponse_Tariff) GetType() string {
if x != nil {
return x.Type
}
return ""
}
func (x *CalculateProductTariffsResponse_Tariff) GetAmount() int64 {
if x != nil {
return x.Amount
}
return 0
}
func (x *CalculateProductTariffsResponse_Tariff) GetCurrency() string {
if x != nil {
return x.Currency
}
return ""
}
func (x *CalculateProductTariffsResponse_Tariff) GetParameters() []*CalculateProductTariffsResponse_Parameter {
if x != nil {
return x.Parameters
}
return nil
}
type CalculateProductTariffsResponse_Offers struct {
state protoimpl.MessageState `protogen:"open.v1"`
Offer *CalculateProductTariffsResponse_Offer `protobuf:"bytes,1,opt,name=offer,proto3" json:"offer,omitempty"`
Tariffs []*CalculateProductTariffsResponse_Tariff `protobuf:"bytes,2,rep,name=tariffs,proto3" json:"tariffs,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *CalculateProductTariffsResponse_Offers) Reset() {
*x = CalculateProductTariffsResponse_Offers{}
mi := &file_yandexmarket_products_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *CalculateProductTariffsResponse_Offers) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CalculateProductTariffsResponse_Offers) ProtoMessage() {}
func (x *CalculateProductTariffsResponse_Offers) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[9]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CalculateProductTariffsResponse_Offers.ProtoReflect.Descriptor instead.
func (*CalculateProductTariffsResponse_Offers) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{1, 3}
}
func (x *CalculateProductTariffsResponse_Offers) GetOffer() *CalculateProductTariffsResponse_Offer {
if x != nil {
return x.Offer
}
return nil
}
func (x *CalculateProductTariffsResponse_Offers) GetTariffs() []*CalculateProductTariffsResponse_Tariff {
if x != nil {
return x.Tariffs
}
return nil
}
type GetProductsResponse_Offer struct {
state protoimpl.MessageState `protogen:"open.v1"`
MarketCategoryId int64 `protobuf:"varint,1,opt,name=market_category_id,json=marketCategoryId,proto3" json:"market_category_id,omitempty"`
WeightDimensions *GetProductsResponse_Offer_WeightDimensions `protobuf:"bytes,2,opt,name=weight_dimensions,json=weightDimensions,proto3" json:"weight_dimensions,omitempty"`
BasicPrice *GetProductsResponse_Offer_BasicPrice `protobuf:"bytes,3,opt,name=basic_price,json=basicPrice,proto3" json:"basic_price,omitempty"`
OfferId string `protobuf:"bytes,4,opt,name=offer_id,json=offerId,proto3" json:"offer_id,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetProductsResponse_Offer) Reset() {
*x = GetProductsResponse_Offer{}
mi := &file_yandexmarket_products_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetProductsResponse_Offer) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetProductsResponse_Offer) ProtoMessage() {}
func (x *GetProductsResponse_Offer) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[10]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetProductsResponse_Offer.ProtoReflect.Descriptor instead.
func (*GetProductsResponse_Offer) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{3, 0}
}
func (x *GetProductsResponse_Offer) GetMarketCategoryId() int64 {
if x != nil {
return x.MarketCategoryId
}
return 0
}
func (x *GetProductsResponse_Offer) GetWeightDimensions() *GetProductsResponse_Offer_WeightDimensions {
if x != nil {
return x.WeightDimensions
}
return nil
}
func (x *GetProductsResponse_Offer) GetBasicPrice() *GetProductsResponse_Offer_BasicPrice {
if x != nil {
return x.BasicPrice
}
return nil
}
func (x *GetProductsResponse_Offer) GetOfferId() string {
if x != nil {
return x.OfferId
}
return ""
}
type GetProductsResponse_Offer_WeightDimensions struct {
state protoimpl.MessageState `protogen:"open.v1"`
Length float32 `protobuf:"fixed32,1,opt,name=length,proto3" json:"length,omitempty"`
Width float32 `protobuf:"fixed32,2,opt,name=width,proto3" json:"width,omitempty"`
Height float32 `protobuf:"fixed32,3,opt,name=height,proto3" json:"height,omitempty"`
Weight float32 `protobuf:"fixed32,4,opt,name=weight,proto3" json:"weight,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetProductsResponse_Offer_WeightDimensions) Reset() {
*x = GetProductsResponse_Offer_WeightDimensions{}
mi := &file_yandexmarket_products_proto_msgTypes[11]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetProductsResponse_Offer_WeightDimensions) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetProductsResponse_Offer_WeightDimensions) ProtoMessage() {}
func (x *GetProductsResponse_Offer_WeightDimensions) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[11]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetProductsResponse_Offer_WeightDimensions.ProtoReflect.Descriptor instead.
func (*GetProductsResponse_Offer_WeightDimensions) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{3, 0, 0}
}
func (x *GetProductsResponse_Offer_WeightDimensions) GetLength() float32 {
if x != nil {
return x.Length
}
return 0
}
func (x *GetProductsResponse_Offer_WeightDimensions) GetWidth() float32 {
if x != nil {
return x.Width
}
return 0
}
func (x *GetProductsResponse_Offer_WeightDimensions) GetHeight() float32 {
if x != nil {
return x.Height
}
return 0
}
func (x *GetProductsResponse_Offer_WeightDimensions) GetWeight() float32 {
if x != nil {
return x.Weight
}
return 0
}
type GetProductsResponse_Offer_BasicPrice struct {
state protoimpl.MessageState `protogen:"open.v1"`
Value float32 `protobuf:"fixed32,1,opt,name=value,proto3" json:"value,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetProductsResponse_Offer_BasicPrice) Reset() {
*x = GetProductsResponse_Offer_BasicPrice{}
mi := &file_yandexmarket_products_proto_msgTypes[12]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetProductsResponse_Offer_BasicPrice) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetProductsResponse_Offer_BasicPrice) ProtoMessage() {}
func (x *GetProductsResponse_Offer_BasicPrice) ProtoReflect() protoreflect.Message {
mi := &file_yandexmarket_products_proto_msgTypes[12]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetProductsResponse_Offer_BasicPrice.ProtoReflect.Descriptor instead.
func (*GetProductsResponse_Offer_BasicPrice) Descriptor() ([]byte, []int) {
return file_yandexmarket_products_proto_rawDescGZIP(), []int{3, 0, 1}
}
func (x *GetProductsResponse_Offer_BasicPrice) GetValue() float32 {
if x != nil {
return x.Value
}
return 0
}
var File_yandexmarket_products_proto protoreflect.FileDescriptor
const file_yandexmarket_products_proto_rawDesc = "" +
"\n" +
"\x1byandexmarket/products.proto\x12\x15yandexmarket.products2\x11\n" +
"\x0fProductsServiceB\x19Z\x17./yandexmarket/productsb\x06proto3"
"\x1byandexmarket/products.proto\x12\x15yandexmarket.products\"\xce\x04\n" +
"\x1eCalculateProductTariffsRequest\x12%\n" +
"\x0emarketplace_id\x18\x01 \x01(\x03R\rmarketplaceId\x12`\n" +
"\n" +
"parameters\x18\x02 \x01(\v2@.yandexmarket.products.CalculateProductTariffsRequest.ParametersR\n" +
"parameters\x12T\n" +
"\x06offers\x18\x03 \x03(\v2<.yandexmarket.products.CalculateProductTariffsRequest.OffersR\x06offers\x1a\xb9\x01\n" +
"\x06Offers\x12\x1f\n" +
"\vcategory_id\x18\x01 \x01(\x03R\n" +
"categoryId\x12\x14\n" +
"\x05price\x18\x02 \x01(\x03R\x05price\x12\x16\n" +
"\x06length\x18\x03 \x01(\x03R\x06length\x12\x14\n" +
"\x05width\x18\x04 \x01(\x03R\x05width\x12\x16\n" +
"\x06height\x18\x05 \x01(\x03R\x06height\x12\x16\n" +
"\x06weight\x18\x06 \x01(\x03R\x06weight\x12\x1a\n" +
"\bquantity\x18\a \x01(\x03R\bquantity\x1a\x90\x01\n" +
"\n" +
"Parameters\x12\x1f\n" +
"\vcampaign_id\x18\x01 \x01(\x03R\n" +
"campaignId\x12'\n" +
"\x0fselling_program\x18\x02 \x01(\tR\x0esellingProgram\x12\x1c\n" +
"\tfrequency\x18\x03 \x01(\tR\tfrequency\x12\x1a\n" +
"\bcurrency\x18\x04 \x01(\tR\bcurrency\"\xd7\x05\n" +
"\x1fCalculateProductTariffsResponse\x12U\n" +
"\x06offers\x18\x01 \x03(\v2=.yandexmarket.products.CalculateProductTariffsResponse.OffersR\x06offers\x1a\xb8\x01\n" +
"\x05Offer\x12\x1f\n" +
"\vcategory_id\x18\x01 \x01(\x03R\n" +
"categoryId\x12\x14\n" +
"\x05price\x18\x02 \x01(\x03R\x05price\x12\x16\n" +
"\x06length\x18\x03 \x01(\x03R\x06length\x12\x14\n" +
"\x05width\x18\x04 \x01(\x03R\x05width\x12\x16\n" +
"\x06height\x18\x05 \x01(\x03R\x06height\x12\x16\n" +
"\x06weight\x18\x06 \x01(\x03R\x06weight\x12\x1a\n" +
"\bquantity\x18\a \x01(\x03R\bquantity\x1a5\n" +
"\tParameter\x12\x12\n" +
"\x04name\x18\x01 \x01(\tR\x04name\x12\x14\n" +
"\x05value\x18\x02 \x01(\tR\x05value\x1a\xb2\x01\n" +
"\x06Tariff\x12\x12\n" +
"\x04type\x18\x01 \x01(\tR\x04type\x12\x16\n" +
"\x06amount\x18\x02 \x01(\x03R\x06amount\x12\x1a\n" +
"\bcurrency\x18\x03 \x01(\tR\bcurrency\x12`\n" +
"\n" +
"parameters\x18\x04 \x03(\v2@.yandexmarket.products.CalculateProductTariffsResponse.ParameterR\n" +
"parameters\x1a\xb5\x01\n" +
"\x06Offers\x12R\n" +
"\x05offer\x18\x01 \x01(\v2<.yandexmarket.products.CalculateProductTariffsResponse.OfferR\x05offer\x12W\n" +
"\atariffs\x18\x02 \x03(\v2=.yandexmarket.products.CalculateProductTariffsResponse.TariffR\atariffs\"X\n" +
"\x12GetProductsRequest\x12%\n" +
"\x0emarketplace_id\x18\x01 \x01(\x03R\rmarketplaceId\x12\x1b\n" +
"\toffer_ids\x18\x02 \x03(\tR\bofferIds\"\x96\x04\n" +
"\x13GetProductsResponse\x12H\n" +
"\x06offers\x18\x01 \x03(\v20.yandexmarket.products.GetProductsResponse.OfferR\x06offers\x1a\xb4\x03\n" +
"\x05Offer\x12,\n" +
"\x12market_category_id\x18\x01 \x01(\x03R\x10marketCategoryId\x12n\n" +
"\x11weight_dimensions\x18\x02 \x01(\v2A.yandexmarket.products.GetProductsResponse.Offer.WeightDimensionsR\x10weightDimensions\x12\\\n" +
"\vbasic_price\x18\x03 \x01(\v2;.yandexmarket.products.GetProductsResponse.Offer.BasicPriceR\n" +
"basicPrice\x12\x19\n" +
"\boffer_id\x18\x04 \x01(\tR\aofferId\x1ap\n" +
"\x10WeightDimensions\x12\x16\n" +
"\x06length\x18\x01 \x01(\x02R\x06length\x12\x14\n" +
"\x05width\x18\x02 \x01(\x02R\x05width\x12\x16\n" +
"\x06height\x18\x03 \x01(\x02R\x06height\x12\x16\n" +
"\x06weight\x18\x04 \x01(\x02R\x06weight\x1a\"\n" +
"\n" +
"BasicPrice\x12\x14\n" +
"\x05value\x18\x01 \x01(\x02R\x05value2\x86\x02\n" +
"\x0fProductsService\x12\x8a\x01\n" +
"\x17CalculateProductTariffs\x125.yandexmarket.products.CalculateProductTariffsRequest\x1a6.yandexmarket.products.CalculateProductTariffsResponse0\x01\x12f\n" +
"\vGetProducts\x12).yandexmarket.products.GetProductsRequest\x1a*.yandexmarket.products.GetProductsResponse0\x01B\x19Z\x17./yandexmarket/productsb\x06proto3"
var file_yandexmarket_products_proto_goTypes = []any{}
var (
file_yandexmarket_products_proto_rawDescOnce sync.Once
file_yandexmarket_products_proto_rawDescData []byte
)
func file_yandexmarket_products_proto_rawDescGZIP() []byte {
file_yandexmarket_products_proto_rawDescOnce.Do(func() {
file_yandexmarket_products_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_yandexmarket_products_proto_rawDesc), len(file_yandexmarket_products_proto_rawDesc)))
})
return file_yandexmarket_products_proto_rawDescData
}
var file_yandexmarket_products_proto_msgTypes = make([]protoimpl.MessageInfo, 13)
var file_yandexmarket_products_proto_goTypes = []any{
(*CalculateProductTariffsRequest)(nil), // 0: yandexmarket.products.CalculateProductTariffsRequest
(*CalculateProductTariffsResponse)(nil), // 1: yandexmarket.products.CalculateProductTariffsResponse
(*GetProductsRequest)(nil), // 2: yandexmarket.products.GetProductsRequest
(*GetProductsResponse)(nil), // 3: yandexmarket.products.GetProductsResponse
(*CalculateProductTariffsRequest_Offers)(nil), // 4: yandexmarket.products.CalculateProductTariffsRequest.Offers
(*CalculateProductTariffsRequest_Parameters)(nil), // 5: yandexmarket.products.CalculateProductTariffsRequest.Parameters
(*CalculateProductTariffsResponse_Offer)(nil), // 6: yandexmarket.products.CalculateProductTariffsResponse.Offer
(*CalculateProductTariffsResponse_Parameter)(nil), // 7: yandexmarket.products.CalculateProductTariffsResponse.Parameter
(*CalculateProductTariffsResponse_Tariff)(nil), // 8: yandexmarket.products.CalculateProductTariffsResponse.Tariff
(*CalculateProductTariffsResponse_Offers)(nil), // 9: yandexmarket.products.CalculateProductTariffsResponse.Offers
(*GetProductsResponse_Offer)(nil), // 10: yandexmarket.products.GetProductsResponse.Offer
(*GetProductsResponse_Offer_WeightDimensions)(nil), // 11: yandexmarket.products.GetProductsResponse.Offer.WeightDimensions
(*GetProductsResponse_Offer_BasicPrice)(nil), // 12: yandexmarket.products.GetProductsResponse.Offer.BasicPrice
}
var file_yandexmarket_products_proto_depIdxs = []int32{
0, // [0:0] is the sub-list for method output_type
0, // [0:0] is the sub-list for method input_type
0, // [0:0] is the sub-list for extension type_name
0, // [0:0] is the sub-list for extension extendee
0, // [0:0] is the sub-list for field type_name
5, // 0: yandexmarket.products.CalculateProductTariffsRequest.parameters:type_name -> yandexmarket.products.CalculateProductTariffsRequest.Parameters
4, // 1: yandexmarket.products.CalculateProductTariffsRequest.offers:type_name -> yandexmarket.products.CalculateProductTariffsRequest.Offers
9, // 2: yandexmarket.products.CalculateProductTariffsResponse.offers:type_name -> yandexmarket.products.CalculateProductTariffsResponse.Offers
10, // 3: yandexmarket.products.GetProductsResponse.offers:type_name -> yandexmarket.products.GetProductsResponse.Offer
7, // 4: yandexmarket.products.CalculateProductTariffsResponse.Tariff.parameters:type_name -> yandexmarket.products.CalculateProductTariffsResponse.Parameter
6, // 5: yandexmarket.products.CalculateProductTariffsResponse.Offers.offer:type_name -> yandexmarket.products.CalculateProductTariffsResponse.Offer
8, // 6: yandexmarket.products.CalculateProductTariffsResponse.Offers.tariffs:type_name -> yandexmarket.products.CalculateProductTariffsResponse.Tariff
11, // 7: yandexmarket.products.GetProductsResponse.Offer.weight_dimensions:type_name -> yandexmarket.products.GetProductsResponse.Offer.WeightDimensions
12, // 8: yandexmarket.products.GetProductsResponse.Offer.basic_price:type_name -> yandexmarket.products.GetProductsResponse.Offer.BasicPrice
0, // 9: yandexmarket.products.ProductsService.CalculateProductTariffs:input_type -> yandexmarket.products.CalculateProductTariffsRequest
2, // 10: yandexmarket.products.ProductsService.GetProducts:input_type -> yandexmarket.products.GetProductsRequest
1, // 11: yandexmarket.products.ProductsService.CalculateProductTariffs:output_type -> yandexmarket.products.CalculateProductTariffsResponse
3, // 12: yandexmarket.products.ProductsService.GetProducts:output_type -> yandexmarket.products.GetProductsResponse
11, // [11:13] is the sub-list for method output_type
9, // [9:11] is the sub-list for method input_type
9, // [9:9] is the sub-list for extension type_name
9, // [9:9] is the sub-list for extension extendee
0, // [0:9] is the sub-list for field type_name
}
func init() { file_yandexmarket_products_proto_init() }
@@ -47,12 +959,13 @@ func file_yandexmarket_products_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_yandexmarket_products_proto_rawDesc), len(file_yandexmarket_products_proto_rawDesc)),
NumEnums: 0,
NumMessages: 0,
NumMessages: 13,
NumExtensions: 0,
NumServices: 1,
},
GoTypes: file_yandexmarket_products_proto_goTypes,
DependencyIndexes: file_yandexmarket_products_proto_depIdxs,
MessageInfos: file_yandexmarket_products_proto_msgTypes,
}.Build()
File_yandexmarket_products_proto = out.File
file_yandexmarket_products_proto_goTypes = nil

View File

@@ -7,7 +7,10 @@
package products
import (
context "context"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
)
// This is a compile-time assertion to ensure that this generated file
@@ -15,10 +18,17 @@ import (
// Requires gRPC-Go v1.64.0 or later.
const _ = grpc.SupportPackageIsVersion9
const (
ProductsService_CalculateProductTariffs_FullMethodName = "/yandexmarket.products.ProductsService/CalculateProductTariffs"
ProductsService_GetProducts_FullMethodName = "/yandexmarket.products.ProductsService/GetProducts"
)
// ProductsServiceClient is the client API for ProductsService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type ProductsServiceClient interface {
CalculateProductTariffs(ctx context.Context, in *CalculateProductTariffsRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[CalculateProductTariffsResponse], error)
GetProducts(ctx context.Context, in *GetProductsRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[GetProductsResponse], error)
}
type productsServiceClient struct {
@@ -29,10 +39,50 @@ func NewProductsServiceClient(cc grpc.ClientConnInterface) ProductsServiceClient
return &productsServiceClient{cc}
}
func (c *productsServiceClient) CalculateProductTariffs(ctx context.Context, in *CalculateProductTariffsRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[CalculateProductTariffsResponse], error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
stream, err := c.cc.NewStream(ctx, &ProductsService_ServiceDesc.Streams[0], ProductsService_CalculateProductTariffs_FullMethodName, cOpts...)
if err != nil {
return nil, err
}
x := &grpc.GenericClientStream[CalculateProductTariffsRequest, CalculateProductTariffsResponse]{ClientStream: stream}
if err := x.ClientStream.SendMsg(in); err != nil {
return nil, err
}
if err := x.ClientStream.CloseSend(); err != nil {
return nil, err
}
return x, nil
}
// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ProductsService_CalculateProductTariffsClient = grpc.ServerStreamingClient[CalculateProductTariffsResponse]
func (c *productsServiceClient) GetProducts(ctx context.Context, in *GetProductsRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[GetProductsResponse], error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
stream, err := c.cc.NewStream(ctx, &ProductsService_ServiceDesc.Streams[1], ProductsService_GetProducts_FullMethodName, cOpts...)
if err != nil {
return nil, err
}
x := &grpc.GenericClientStream[GetProductsRequest, GetProductsResponse]{ClientStream: stream}
if err := x.ClientStream.SendMsg(in); err != nil {
return nil, err
}
if err := x.ClientStream.CloseSend(); err != nil {
return nil, err
}
return x, nil
}
// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ProductsService_GetProductsClient = grpc.ServerStreamingClient[GetProductsResponse]
// ProductsServiceServer is the server API for ProductsService service.
// All implementations must embed UnimplementedProductsServiceServer
// for forward compatibility.
type ProductsServiceServer interface {
CalculateProductTariffs(*CalculateProductTariffsRequest, grpc.ServerStreamingServer[CalculateProductTariffsResponse]) error
GetProducts(*GetProductsRequest, grpc.ServerStreamingServer[GetProductsResponse]) error
mustEmbedUnimplementedProductsServiceServer()
}
@@ -43,6 +93,12 @@ type ProductsServiceServer interface {
// pointer dereference when methods are called.
type UnimplementedProductsServiceServer struct{}
func (UnimplementedProductsServiceServer) CalculateProductTariffs(*CalculateProductTariffsRequest, grpc.ServerStreamingServer[CalculateProductTariffsResponse]) error {
return status.Errorf(codes.Unimplemented, "method CalculateProductTariffs not implemented")
}
func (UnimplementedProductsServiceServer) GetProducts(*GetProductsRequest, grpc.ServerStreamingServer[GetProductsResponse]) error {
return status.Errorf(codes.Unimplemented, "method GetProducts not implemented")
}
func (UnimplementedProductsServiceServer) mustEmbedUnimplementedProductsServiceServer() {}
func (UnimplementedProductsServiceServer) testEmbeddedByValue() {}
@@ -64,6 +120,28 @@ func RegisterProductsServiceServer(s grpc.ServiceRegistrar, srv ProductsServiceS
s.RegisterService(&ProductsService_ServiceDesc, srv)
}
func _ProductsService_CalculateProductTariffs_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(CalculateProductTariffsRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(ProductsServiceServer).CalculateProductTariffs(m, &grpc.GenericServerStream[CalculateProductTariffsRequest, CalculateProductTariffsResponse]{ServerStream: stream})
}
// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ProductsService_CalculateProductTariffsServer = grpc.ServerStreamingServer[CalculateProductTariffsResponse]
func _ProductsService_GetProducts_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(GetProductsRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(ProductsServiceServer).GetProducts(m, &grpc.GenericServerStream[GetProductsRequest, GetProductsResponse]{ServerStream: stream})
}
// This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ProductsService_GetProductsServer = grpc.ServerStreamingServer[GetProductsResponse]
// ProductsService_ServiceDesc is the grpc.ServiceDesc for ProductsService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
@@ -71,6 +149,17 @@ var ProductsService_ServiceDesc = grpc.ServiceDesc{
ServiceName: "yandexmarket.products.ProductsService",
HandlerType: (*ProductsServiceServer)(nil),
Methods: []grpc.MethodDesc{},
Streams: []grpc.StreamDesc{},
Metadata: "yandexmarket/products.proto",
Streams: []grpc.StreamDesc{
{
StreamName: "CalculateProductTariffs",
Handler: _ProductsService_CalculateProductTariffs_Handler,
ServerStreams: true,
},
{
StreamName: "GetProducts",
Handler: _ProductsService_GetProducts_Handler,
ServerStreams: true,
},
},
Metadata: "yandexmarket/products.proto",
}