You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

225 lines
7.1 KiB

syntax = "proto2";
import "steammessages_base.proto";
import "steammessages_unified_base.proto";
option py_generic_services = true;
message CInventory_GetInventory_Request {
optional uint32 appid = 1;
optional uint64 steamid = 2;
}
message CInventory_Response {
optional string etag = 1;
repeated uint64 removeditemids = 2;
optional string item_json = 3;
optional string itemdef_json = 4;
optional bytes ticket = 5;
optional bool replayed = 6 [(description) = "If true, the requestid given was processed earlier."];
}
message CInventory_ExchangeItem_Request {
optional uint32 appid = 1;
optional uint64 steamid = 2;
repeated uint64 materialsitemid = 3;
repeated uint32 materialsquantity = 4;
optional uint64 outputitemdefid = 5;
}
message CInventory_GetEligiblePromoItemDefIDs_Request {
optional uint32 appid = 1;
optional uint64 steamid = 2;
}
message CInventory_GetEligiblePromoItemDefIDs_Response {
repeated uint64 itemdefids = 1;
}
message CInventory_AddItem_Request {
optional uint32 appid = 1;
repeated uint64 itemdefid = 2;
repeated string itempropsjson = 3;
optional uint64 steamid = 4;
optional bool notify = 5 [(description) = "Should notify the user that the item was added to their Steam Inventory."];
optional uint64 requestid = 6;
optional bool trade_restriction = 7 [(description) = "If true, apply the default trade and market restriction times to this item."];
optional bool is_purchase = 8 [default = false, (description) = "If set, treat requestid as a txnid and create this item as a result of user microtransaction purchase."];
}
message CInventory_ModifyItems_Request {
message ItemPropertyUpdate {
optional uint64 itemid = 1;
optional bool remove_property = 2;
optional string property_name = 3;
optional bool property_value_bool = 4;
optional int64 property_value_int = 5;
optional string property_value_string = 6;
optional float property_value_float = 7;
}
optional uint32 appid = 1;
optional uint64 steamid = 2;
repeated .CInventory_ModifyItems_Request.ItemPropertyUpdate updates = 3;
optional uint32 timestamp = 4;
}
message CInventory_ConsumePlaytime_Request {
optional uint32 appid = 1;
optional uint64 itemdefid = 2;
}
message CInventory_ConsumeItem_Request {
optional uint32 appid = 1;
optional uint64 itemid = 2;
optional uint32 quantity = 3;
optional string timestamp = 4;
optional uint64 steamid = 5;
optional uint64 requestid = 6;
}
message CInventory_DevSetNextDrop_Request {
optional uint32 appid = 1;
optional uint64 itemdefid = 2;
optional string droptime = 3;
}
message CInventory_SplitItemStack_Request {
optional uint32 appid = 1;
optional uint64 itemid = 2;
optional uint32 quantity = 3;
optional uint64 steamid = 5;
}
message CInventory_CombineItemStacks_Request {
optional uint32 appid = 1;
optional uint64 fromitemid = 2;
optional uint64 destitemid = 3;
optional uint32 quantity = 4;
optional fixed64 steamid = 7;
}
message CInventory_GetItemDefMeta_Request {
optional uint32 appid = 1;
}
message CInventory_GetItemDefMeta_Response {
optional uint32 modified = 1;
optional string digest = 2;
}
message CInventory_GetUserPurchaseInfo_Request {
}
message CInventory_GetUserPurchaseInfo_Response {
optional int32 ecurrency = 1;
}
message CInventory_PurchaseInit_Request {
message LineItem {
optional uint64 itemdefid = 1;
optional uint32 quantity = 2;
}
optional uint32 appid = 1;
optional int32 language = 2;
repeated .CInventory_PurchaseInit_Request.LineItem line_items = 3;
}
message CInventory_PurchaseInit_Response {
optional uint64 orderid = 1;
optional uint64 transid = 2;
}
message CInventory_PurchaseFinalize_Request {
optional uint32 appid = 1;
optional int32 language = 2;
optional uint64 orderid = 3;
}
message CInventory_InspectItem_Request {
optional uint64 itemdefid = 1;
optional fixed64 itemid = 2;
optional string tags = 3;
}
message CInventoryClient_NewItems_Notification {
optional uint32 appid = 1;
optional .CInventory_Response inventory_response = 2;
}
service Inventory {
option (service_description) = "A service that provides access to inventory";
rpc GetInventory (.CInventory_GetInventory_Request) returns (.CInventory_Response) {
option (method_description) = "Retrieves a users inventory as a big JSON blob";
}
rpc ExchangeItem (.CInventory_ExchangeItem_Request) returns (.CInventory_Response) {
option (method_description) = "Craft an item in a user's inventory";
}
rpc GetEligiblePromoItemDefIDs (.CInventory_GetEligiblePromoItemDefIDs_Request) returns (.CInventory_GetEligiblePromoItemDefIDs_Response) {
option (method_description) = "Returns a list of promo item defs the user is eligible for";
}
rpc AddPromoItem (.CInventory_AddItem_Request) returns (.CInventory_Response) {
option (method_description) = "Adds a promo item to a user's inventory";
}
rpc SafeModifyItems (.CInventory_ModifyItems_Request) returns (.CInventory_Response) {
option (method_description) = "Modify an item in a user's inventory (safe properties only)";
}
rpc ConsumePlaytime (.CInventory_ConsumePlaytime_Request) returns (.CInventory_Response) {
option (method_description) = "Consumes playtime and possibly returns a granted item";
}
rpc ConsumeItem (.CInventory_ConsumeItem_Request) returns (.CInventory_Response) {
option (method_description) = "Consume an item";
}
rpc DevGenerateItem (.CInventory_AddItem_Request) returns (.CInventory_Response) {
option (method_description) = "Grant an item when in developer mode";
}
rpc DevSetNextDrop (.CInventory_DevSetNextDrop_Request) returns (.CInventory_Response) {
option (method_description) = "Consume an item";
}
rpc SplitItemStack (.CInventory_SplitItemStack_Request) returns (.CInventory_Response) {
option (method_description) = "Split an item stack into two stacks";
}
rpc CombineItemStacks (.CInventory_CombineItemStacks_Request) returns (.CInventory_Response) {
option (method_description) = "Combine two stacks of items";
}
rpc GetItemDefMeta (.CInventory_GetItemDefMeta_Request) returns (.CInventory_GetItemDefMeta_Response) {
option (method_description) = "Get metadata about the current item definition for this game.";
}
rpc GetUserPurchaseInfo (.CInventory_GetUserPurchaseInfo_Request) returns (.CInventory_GetUserPurchaseInfo_Response) {
option (method_description) = "Returns information about the user such as their currency";
}
rpc PurchaseInit (.CInventory_PurchaseInit_Request) returns (.CInventory_PurchaseInit_Response) {
option (method_description) = "Initializes a purchase for the user";
}
rpc PurchaseFinalize (.CInventory_PurchaseFinalize_Request) returns (.CInventory_Response) {
option (method_description) = "Finalizes a purchase for the user";
}
rpc InspectItem (.CInventory_InspectItem_Request) returns (.CInventory_Response) {
option (method_description) = "Get item detail given a valid inspection token";
}
}
service InventoryClient {
option (service_description) = "Client notifications inventory service events";
option (service_execution_site) = k_EProtoExecutionSiteSteamClient;
rpc NotifyNewItems (.CInventoryClient_NewItems_Notification) returns (.NoResponse) {
option (method_description) = "Notify client that the user received new items";
}
}