|
Beamable SDK
|
This type defines the Client main entry point for the Inventory feature. More...


Public Member Functions | |
| AbsInventoryApi (IBeamableRequester requester, IUserContext userContext) | |
| Promise< PreviewCurrencyGainResponse > | PreviewCurrencyGain (Dictionary< string, long > currencyIdsToAmount) |
| Players may sometimes receive additional currency as a result of qualifying for a VIP Tier This API previews what that amount of currency would be ahead of an update. More... | |
| Promise< GetMultipliersResponse > | GetMultipliers () |
| Provides the VIP Bonus multipliers that are applicable for this player according to their tier. More... | |
| Promise< long > | GetCurrency (CurrencyRef currency) |
| Gets the currency. More... | |
| Promise< Unit > | AddItem (ItemRef itemRef, Dictionary< string, string > properties=null, string transaction=null) |
| Add an instance of the given itemRef to the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | AddItem (string contentId, Dictionary< string, string > properties=null, string transaction=null) |
| Add an item instance of the given contentId to the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | DeleteItem (string contentId, long itemId, string transaction=null) |
| Remove an item instance from the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | UpdateItem (ItemRef itemRef, long itemId, Dictionary< string, string > properties, string transaction=null) |
| Update the instance level item properties of an item in the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | UpdateItem (string contentId, long itemId, Dictionary< string, string > properties, string transaction=null) |
| Update the instance level item properties of an item in the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | SetCurrency (CurrencyRef currency, long amount, string transaction=null) |
| Sets the currency. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | SetCurrencyProperties (string currencyId, List< CurrencyProperty > properties, string transaction=null) |
| Set the CurrencyProperty values for a player's currency More... | |
| Promise< Unit > | SetCurrencyProperties (CurrencyRef currency, List< CurrencyProperty > properties, string transaction=null) |
| Set the CurrencyProperty values for a player's currency More... | |
| Promise< Unit > | AddCurrency (string currencyId, long amount, string transaction=null) |
| Adds the currency If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | AddCurrency (CurrencyRef currency, long amount, string transaction=null) |
| Adds the currency If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | SetCurrencies (Dictionary< CurrencyRef, long > currencyToAmount, string transaction=null) |
| Set multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | AddCurrencies (Dictionary< string, long > currencyIdsToAmount, string transaction=null) |
| Add multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | AddCurrencies (Dictionary< CurrencyRef, long > currencyToAmount, string transaction=null) |
| Add multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | SetCurrency (string currencyId, long amount, string transaction=null) |
| Sets the currency. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Unit > | SetCurrencies (Dictionary< string, long > currencyIdsToAmount, string transaction=null) |
| Set multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method. More... | |
| Promise< Dictionary< string, long > > | GetCurrencies (string[] currencyIds) |
| Get a set of currency values for the current player. More... | |
| Promise< Dictionary< CurrencyRef, long > > | GetCurrencies (CurrencyRef[] currencyRefs) |
| Get a set of currency values for the current player. More... | |
| Promise< long > | GetCurrency (string currencyId) |
| Gets the currency. More... | |
| Promise< Unit > | Update (Action< InventoryUpdateBuilder > action, string transaction=null) |
| Promise< Unit > | Update (InventoryUpdateBuilder builder, string transaction=null) |
| Perform multiple updates to the player's inventory in one network call. The InventoryUpdateBuilder that you pass to this method will be converted into one update call to Beamable. More... | |
| Promise< List< InventoryObject< TContent > > > | ViewToItems< TContent > (InventoryView view, IEnumerable< string > filter=null) |
| Promise< List< InventoryObject< TContent > > > | GetItems< TContent > () |
| Get every InventoryObject<TContent> that is of a specific item content type. More... | |
| Promise< List< InventoryObject< TContent > > > | GetItems< TContent > (params ItemRef< TContent >[] itemReferences) |
| Get the InventoryObject<TContent> that are of a specific item content type and match the given itemReferences More... | |
| void | GetLatestItems (ItemRef itemRef) |
| abstract Promise< InventoryView > | GetCurrent (string scope="") |
| Get the current data from the given scope. More... | |
Public Member Functions inherited from Beamable.Common.Api.ISupportsGet< InventoryView > | |
| Promise< TData > | GetCurrent (string scope="") |
| Manually fetch the available data. If the server hasn't delivered a new update, this method will not return the absolute latest data unless you pass forceRefresh as true. More... | |
Static Public Attributes | |
| const string | SERVICE_OBJECT = "object/inventory" |
Protected Member Functions | |
| string | CreateRefreshUrl (string scope) |
Properties | |
| IBeamableRequester | Requester [get] |
| IUserContext | UserContext [get] |
This type defines the Client main entry point for the Inventory feature.

|
inline |
Add multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currencyToAmount | A dictionary where the keys are CurrencyRefs, and the values are the new currency values for the player |
| transaction | An inventory transaction ID. Leave this argument empty. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Add multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currencyIdsToAmount | A dictionary where the keys are content IDs of the currency, and the values are the new currency values for the player |
| transaction | An inventory transaction ID. Leave this argument empty. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Adds the currency If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currency | |
| amount | |
| transaction |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Adds the currency If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currencyId | |
| amount | |
| transaction |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
| Promise< Unit > Beamable.Common.Api.Inventory.AbsInventoryApi.AddItem | ( | ItemRef | itemRef, |
| Dictionary< string, string > | properties = null, |
||
| string | transaction = null |
||
| ) |
Add an instance of the given itemRef to the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| itemRef | A ItemRef |
| properties | a set of instance properties for the new item |
| transaction | An inventory transaction id |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Add an item instance of the given contentId to the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| contentId | A content ID of the item type |
| properties | a set of instance properties for the new item |
| transaction | An inventory transaction ID. Leave this argument empty. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Remove an item instance from the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| contentId | The content ID of the type of item to remove |
| itemId | The runtime ID of the item to remove |
| transaction | an inventory transaction ID |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Get a set of currency values for the current player.
| currencyRefs | CurrencyRefs for the currencies that will be returned |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Get a set of currency values for the current player.
| currencyIds | the content IDs for the currencies that will be returned |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Gets the currency.
| currency | A CurrencyRef |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Gets the currency.
| currencyId |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
pure virtual |
Get the current data from the given scope.
| scope |
Implemented in Beamable.Api.Inventory.InventoryService.
|
inline |
Get every InventoryObject<TContent> that is of a specific item content type.
| TContent | The type of content to retrieve. All children types will be included the result. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
| TContent | : | ItemContent | |
| TContent | : | new() |
|
inline |
Get the InventoryObject<TContent> that are of a specific item content type and match the given itemReferences
| itemReferences | Filter for only the items that match the given ItemRef<TContent> types. |
| TContent | The type of content to retrieve. All children types will be included the result. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
| TContent | : | ItemContent | |
| TContent | : | new() |
|
inline |
Provides the VIP Bonus multipliers that are applicable for this player according to their tier.
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Players may sometimes receive additional currency as a result of qualifying for a VIP Tier This API previews what that amount of currency would be ahead of an update.
| currencyIdsToAmount |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Set multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currencyToAmount | A dictionary where the keys are CurrencyRefs, and the values are the new currency values for the player |
| transaction | An inventory transaction ID. Leave this argument empty. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Set multiple currency values. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currencyIdsToAmount | A dictionary where the keys are content IDs of the currency, and the values are the new currency values for the player |
| transaction | An inventory transaction ID. Leave this argument empty. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Sets the currency. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currency | |
| amount | |
| transaction |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Sets the currency. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| currencyId | |
| amount | |
| transaction |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Set the CurrencyProperty values for a player's currency
| currency | A CurrencyRef |
| properties | A list of CurrencyProperty values |
| transaction | An inventory transaction id |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Set the CurrencyProperty values for a player's currency
| currencyId | The content id of the currency |
| properties | A list of CurrencyProperty values |
| transaction | An inventory transaction id. |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
| action | A configurator for the InventoryUpdateBuilder. You should configure the builder with all of the inventory updates. If you already have an instance of the builder, use the Update(InventoryUpdateBuilder,string) method instead. |
| transaction | an inventory transaction ID |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Perform multiple updates to the player's inventory in one network call. The InventoryUpdateBuilder that you pass to this method will be converted into one update call to Beamable.
| builder | An InventoryUpdateBuilder containing all of the inventory updates. Use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method to configure an InventoryUpdateBuilder instead. |
| transaction | an inventory transaction ID |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
| Promise< Unit > Beamable.Common.Api.Inventory.AbsInventoryApi.UpdateItem | ( | ItemRef | itemRef, |
| long | itemId, | ||
| Dictionary< string, string > | properties, | ||
| string | transaction = null |
||
| ) |
Update the instance level item properties of an item in the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| itemRef | An ItemRef pointing to the content type of the item to update. |
| itemId | The runtime ID of the item to remove |
| properties | A new set of instance property values for the item. This will overwrite the existing properties. |
| transaction | an inventory transaction ID |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
Update the instance level item properties of an item in the player's inventory. If you need to make multiple inventory updates, use the Update(System.Action<Beamable.Common.Api.Inventory.InventoryUpdateBuilder>,string) method.
| contentId | A content ID pointing to the content type of the item to update. |
| itemId | The runtime ID of the item to remove |
| properties | A new set of instance property values for the item. This will overwrite the existing properties. |
| transaction | an inventory transaction ID |
Implements Beamable.Common.Api.Inventory.IInventoryApi.
|
inline |
| TContent | : | ItemContent | |
| TContent | : | new() |