Files
go-cart-actor/proto/cart.proto

97 lines
2.1 KiB
Protocol Buffer

syntax = "proto3";
package cart_messages;
option go_package = "git.k6n.net/go-cart-actor/proto/cart;cart_messages";
import "google/protobuf/any.proto";
import "google/protobuf/timestamp.proto";
message ClearCartRequest {}
message AddItem {
uint32 item_id = 1;
int32 quantity = 2;
int64 price = 3;
int64 orgPrice = 9;
string sku = 4;
string name = 5;
string image = 6;
int32 stock = 7;
int32 tax = 8;
string brand = 13;
string category = 14;
string category2 = 15;
string category3 = 16;
string category4 = 17;
string category5 = 18;
string disclaimer = 10;
string articleType = 11;
string sellerId = 19;
string sellerName = 20;
string country = 21;
string saleStatus = 24;
optional string outlet = 12;
optional string storeId = 22;
optional uint32 parentId = 23;
string cgm = 25;
optional google.protobuf.Timestamp reservationEndTime = 26;
}
message RemoveItem { uint32 Id = 1; }
message ChangeQuantity {
uint32 Id = 1;
int32 quantity = 2;
}
message SetUserId {
string userId = 1;
}
message LineItemMarking {
uint32 id = 1;
uint32 type = 2;
string marking = 3;
}
message RemoveLineItemMarking {
uint32 id = 1;
}
message SubscriptionAdded {
uint32 itemId = 1;
string detailsId = 3;
string orderReference = 4;
}
message AddVoucher {
string code = 1;
int64 value = 2;
repeated string voucherRules = 3;
string description = 4;
}
message RemoveVoucher { uint32 id = 1; }
message UpsertSubscriptionDetails {
optional string id = 1;
string offeringCode = 2;
string signingType = 3;
google.protobuf.Any data = 4;
}
message Mutation {
oneof type {
ClearCartRequest clear_cart = 1;
AddItem add_item = 2;
RemoveItem remove_item = 3;
ChangeQuantity change_quantity = 4;
SetUserId set_user_id = 5;
LineItemMarking line_item_marking = 6;
RemoveLineItemMarking remove_line_item_marking = 7;
SubscriptionAdded subscription_added = 8;
AddVoucher add_voucher = 20;
RemoveVoucher remove_voucher = 21;
UpsertSubscriptionDetails upsert_subscription_details = 22;
}
}