SysDropAllMyUserItems
Client Cloud Code only. Drops every droppable item in the session user's inventory, without any recovery of the currency paid for them.
Items published to the blockchain (have a blockItemId) and items that have been given away and are awaiting pickup (have giftedTo) are not dropped.
This permanently deletes the user's items and cannot be undone.
One DroppedItem analytics event is recorded for each item definition dropped, with the quantities of that definition's deleted items summed. Items whose item definition has been revoked or deleted are dropped but not reported.
Each user item deleted counts as one bulk API call. Nothing is counted if the user had no droppable items.
| Service | Operation |
|---|---|
| userItems | SYS_DROP_ALL_MY_USER_ITEMS |
Method Parameters
This method takes no parameters.
Usage
- C#
- C++
- Obj-C
- Java
- JavaScript
- Dart
- Roblox
- GDScript
- Lua
- Cloud Code
- Raw
// Cloud Code only. To view example, switch to the Cloud Code tab
// Cloud Code only. To view example, switch to the Cloud Code tab
// Cloud Code only. To view example, switch to the Cloud Code tab
// Cloud Code only. To view example, switch to the Cloud Code tab
// Cloud Code only. To view example, switch to the Cloud Code tab
// Cloud Code only. To view example, switch to the Cloud Code tab
-- N/A
N/A
-- Cloud Code only. To view example, switch to the Cloud Code tab
var userItemsProxy = bridge.getUserItemsServiceProxy();
var postResult = userItemsProxy.sysDropAllMyUserItems();
{
"service": "userItems",
"operation": "SYS_DROP_ALL_MY_USER_ITEMS",
"data": {}
}
JSON Response
{
"data": {
"deletedCount": 12
},
"status": 200
}
deletedCount is the number of user item entries that were deleted. A stackable item counts as one entry, whatever its quantity.
Common Error Codes
Status Codes
| Code | Name | Description |
|---|---|---|
| 40616 | CLOUD_CODE_ONLY_METHOD | The method was called directly from a client. It can only be called from client-session Cloud Code. |